Bring your best ideas to the AI Use Case Contest! Enter to win 40 hours of expert engineering support and bring your vision to life using the powerful combination of Alteryx + AI. Learn more now, or go straight to the submission form.
Start Free Trial

Alteryx Designer Desktop Discussions

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

Split specific word from column with RegEx

Khalisaaliyeva
7 - Meteor

 I want to extract 4 and 2 uppercase words  and the 6-digit number (HB 256895  or EGBJ 125486 like this) next to it. I used ([A-Z]+\s+(\d{6})) RegEx expression in order to apply for salution. But i doesn't work 

Does there have another expression to get this output?

 

 

 

Khalisaaliyeva_2-1659532716773.png

 

 

 

3 REPLIES 3
DataNath
17 - Castor
17 - Castor

Hey @Khalisaaliyeva, I doubt it's the most succinct expression here but this looks to work for your example. Let me know if there's any issues when you apply it to a larger dataset:

 

(\b[A-Z]{4}\s[0-9]{6}\b|\b[A-Z]{2}\s[0-9]{6}\b)

 

DataNath_0-1659533250140.png

 

binuacs
21 - Polaris

@Khalisaaliyeva One way of doing this with the Regex Tokenize method

binuacs_0-1659533382006.png

 

Khalisaaliyeva
7 - Meteor

Thank you for helping it works👍

Labels
Top Solution Authors