Community Spring Cleaning week is here! Join your fellow Maveryx in digging through your old posts and marking comments on them as solved. Learn more here!

Alteryx Designer Desktop Discussions

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

Write Regular Expression

Gamaliel
10 - Fireball

Hello,

 

I am still new to  alteryx, can you teach me how to write regular expression for this?

 

Gamaliel_0-1625129399150.png

 

This is what I entered but it wont work: \d{5}\W[[:alpha:]]+\s\W+\w+\W[[:alpha:]]+

 

Thank you.

4 REPLIES 4
mceleavey
17 - Castor
17 - Castor

Hi @Gamaliel ,

 

What are you trying to do? Can you please provide your expected results?

 

Thanks,

 

M.



Bulien

Gamaliel
10 - Fireball

I intend to use this for replace or match purposes. 

 

Gamaliel_0-1625129846246.png

 

OllieClarke
15 - Aurora
15 - Aurora

Hey @Gamaliel 

The issue with your RegEx is that [[:alpha:]] doesn't include spaces, so "Handsome Gamaliel" isn't being matched (for example).

If you change the [[:alpha:]]s for [a-zA-Z ] (a set of all letters and also spaces), then your RegEx should work:

\d{5}\W[a-zA-Z ]+\W+[a-zA-Z ]+\W[a-zA-Z ]+

OllieClarke_0-1625131136496.png

Hope that helps,

 

Ollie

 

Gamaliel
10 - Fireball

Thank you so much @OllieClarke  this is really helpful.

Labels