We are celebrating the 10-year anniversary of the Alteryx Community! Learn more and join in on the fun here.
Start Free Trial

Alteryx Designer Desktop Discussions

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

Parse text block to rows

brend_bb
5 - Atom

I have a string field that I am trying to parse into rows where each line starts with the date, then the text that follows. Sample: 
ID Number column     Text block column
12345                          5/2/2024 - Random text of varying length 2/8/2024 : Random text of varying length6/15/2022 Random text of varying length 2/16/2022Random text of varying length


Desired Output: 

ID Num col     Text block column
12345             5/2/2024 - Random text of varying length
12345             2/8/2024 : Random text of varying length
12345             6/15/2022  Random text of varying length
12345             2/16/2022Random text of varying length

 

There isn't a set hyphen or anything after the date for me to parse on. What is the best way to tackle this? I'm probably overlooking an easy way, so any help is appreciated!

5 REPLIES 5
flying008
15 - Aurora

Hi, @brend_bb 

 

FYI.

 

Spoiler
\d{1,2}\/\d{1,2}\/\d{4}\D+?(?=\s?\d{1,2}\/\d{1,2}\/\d{4}|$)

录制_2025_05_07_08_15_32_54.gif

 

 

 

Qiu
21 - Polaris
21 - Polaris

@flying008 
Nice one.
I heard about the "Positive Lookahead" but did not know how to use it.

flying008
15 - Aurora

Hi, @Qiu 

 

regex101.com  can help you to try it . 😁

brend_bb
5 - Atom

Thank you so much!!😁

flying008
15 - Aurora

Hi, @brend_bb 

 

If can help you get you want, please mark it as s solution for more share.

Labels
Top Solution Authors