Advent of Code is back! Unwrap daily challenges to sharpen your Alteryx skills and earn badges along the way! Learn more now.
Free Trial

Alteryx Designer Desktop Discussions

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

Best way to isolate just company names from this messy column

novawaly
7 - Meteor

Hi, 

 

I have a column of names that is in very sloppy format. It generally follows a Company name - Stat - City so I was thinking text to columns and split on the first "-" however, some company names will have a "-" in their actual name (is A1-trucking - Las Vegas - NV. What's even worse is some dont have any dashes at all and might only include a company name with no location. 

 

Also, I'll eventually have to do a fuzzy match to match duplicates - is it better to do that before or after I attempt to split out the company names?

 

novawaly_0-1643746290826.png

 

Thank you so much!

 

4 REPLIES 4
binuacs
21 - Polaris

@novawaly @Can you provide the data in an excel sheet?

novawaly
7 - Meteor

added to the original message - sorry should've done that in the first place. 

 

binuacs
21 - Polaris

@novawaly this can be done using RegEx tool

binuacs_0-1643749523551.png

 

novawaly
7 - Meteor

Wow that's amazing. I'm horrible with regex. Just for my own edification, do you happen to know where I can figure out/follow what that's doing?

 

Labels
Top Solution Authors