Join the Alteryx Community’s Maveryx Summer Cup event! Compete, network with others, and earn your gold through a series of challenges from July 24th to August 11th. Learn more about the event here.

Alteryx Designer Desktop Discussions

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

Find and Retrieve Multiple Set Words Within a String

JoeHodgetts
7 - Meteor

Hello,

 

Looking for some help with the following.

 

I have string data that I want to search for pre-defined keywords and then add a column which lists all the keywords that were found. The string is not consistently separated by any particular delimiter and due to human error words can be concatenated. I've tried to crudely represent what I'm trying to achieve using notes on car damage.

 

I've seen some really good articles where people have solved similar queries using find and replace or RegEx, but none have been able to work with messy strings and recall every word found. 

 

Car Damage Example.JPG

Many thanks for any support.

 

Joe

5 REPLIES 5
afv2688
16 - Nebula
16 - Nebula

Hello @JoeHodgetts ,

 

It is not pretty but it does the work 🙂

 

Untitled.png

 

Regards

JoeHodgetts
7 - Meteor

@afv2688 That is the ugliest, most beautiful solution I have seen. Thank you so much.

 

In practice the raw data is huge and with about 100 keywords, so hoping the initial append isn't too scary for it.

 

Joe 

afv2688
16 - Nebula
16 - Nebula

You were right @JoeHodgetts , was really ugly solution. Therefore I am bringing a better one 🙂

 

Untitled.png

 

Regards

JoeHodgetts
7 - Meteor

@afv2688 I think this second method will handle a larger dataset better. Thank you 🙂

Ben_H
11 - Bolide

Hi @JoeHodgetts,

 

I think there's a slightly more straightforward way to do it, not that it makes much difference!

 

Ben_H_0-1637333142487.png

 

Ben_H_1-1637333173989.png

Regards,

 

Ben

Labels