Alteryx Designer Desktop Discussions

Find answers, ask questions, and share expertise about Alteryx Designer Desktop and Intelligence Suite.
SOLVED

Find Exact Matched String from Concatenated String Column

Rahul6777
7 - Meteor

 

CategoryCatloOneTwo Three FourFiveSix
Active,HistoryTRUETRUEFALSEFALSEFALSEFALSEFALSE
Active,5% History TRUEFALSEFALSEFALSEFALSEFALSEFALSE
Directory,Active Image, OwnershipFALSEFALSEFALSETRUETRUEFALSEFALSE
OwnershipFALSEFALSEFALSEFALSETRUEFALSEFALSE
Ownership Details,ActiveTRUEFALSEFALSEFALSEFALSEFALSEFALSE

 

Hi Team,

Please help on the below logic

in Formula Tab
Logic Calculated Based on: -
Catlo
If Contain(Category, "Active") Then "True" Else False Endif
One
If Contain(Category, "History") Then "True" Else False Endif
Two
If Contain(Category, "Ownership") Then "True" Else False Endif

Now what is the challenge if i am using contain function it will take the as true for other column as well some column contain the word.
Eg. Picking True for Active and Active Image
Picking True for Ownership and Ownership details.

So, i want a function which can help me to pick the exact match String for this concatenated column String.

Please advise.

9 REPLIES 9
ShankerV
17 - Castor

Hi @Rahul6777 

 

Please make use of REGEX_Match(String, pattern) function.

 

Many thanks

Shanker V

 

 

Rahul6777
7 - Meteor

I Have tried but now able write Regex_Match Can you please help.

ShankerV
17 - Castor

Hi @Rahul6777 

 

One way of doing this.

 

ShankerV_0-1687425632832.png

 

Step 1: Input

 

ShankerV_1-1687425688879.png

Step 2: 

 

ShankerV_2-1687425721616.png

 

 

Many thanks

Shanker V

Rahul6777
7 - Meteor

Can You Please share the Workflow If Possible ?

ShankerV
17 - Castor

Hi @Rahul6777 

 

Step 3:

 

ShankerV_0-1687425770749.png

 

 

ShankerV_1-1687425779526.png

 

 

Step 4:

 

ShankerV_2-1687425795745.png

 

Step 5:

 

ShankerV_3-1687425815033.png

 

ShankerV_4-1687425824516.png

 

 

Step 6:

 

ShankerV_7-1687425877039.png

 

 

ShankerV_6-1687425864137.png

 

 

Step 7:

 

ShankerV_8-1687425897637.png

 

ShankerV_9-1687425916858.png

 

Many thanks

Shanker V

 

 

Rahul6777
7 - Meteor

 Not Geeting What you have passed Through Input2 Tool, can you please share your workflow so i will try to corelate and check in my scenario.

Thank You

BRRLL99
11 - Bolide

Please try this formula

If REGEX_Match(Category, "^(?!.*Active Image.*).*\bActive\b.*$") Then "True" Else "False" Endif

 

Using this Formula which has Active will be True

Which has Active Image will be False

binuacs
20 - Arcturus

@Rahul6777 Another way of doing this

binuacs_0-1687430113025.png

 

Rahul6777
7 - Meteor

Thank You @binuacs @ShankerV and @BRRLL99  for the help and suggestion here. 

Labels