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.
解決済み

RegEx

SylviaK
アステロイド

Hi 

 

I am trying to get the date out of the comments column using RegEx. 

 

SylviaK_0-1611755714059.png

 

 

I used this expression. but it doesn't seem to work. What am I doing wrong?

 

SylviaK_1-1611755773621.png

 

Many thanks, 

Sylvia

3件の返信3
Ladarthure
14 - Magnetar
14 - Magnetar

Hi @SylviaK,

 

I used this regex, may not be the best but it worked on my side : 

 

(\w+\s\d+\,\s\d{4})\s.+

 

Hope it helped!

AshleyL
Alteryx Alumni (Retired)

Hi @SylviaK,

 

I've attached a sample workflow. I would suggest using Parse and then if you want to convert the new separated date into a date data type, you'd use the DateTime tool.

 

If you wanted to use replace, I would uncheck 'Copy unmatched text to output'.

 

Does this help?

Ashley

neilgallen
クエーサー

In this case you need to replace the \n with \d to signify digits. The rest of the expression should work!

ラベル