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

Text to column using RegEX

HassimDiallo
6 - Meteoroid

Hello, i have sample Data and need to text to column using regEx. the issue is when the expression runs the outputs are Null. 

 

Sample Data

 

Header

0111 1254589789         0000003895 2121245894 000000000000000015 D USD 000000000 0000000

 

 

I am using Parse Output Method

regular expression: (.{5})(.{23})(.{11})(.{10})(.{26})(.{7})(.{4})(.{7})(.{11})(.{11})(.{11})(.{24})(.{40})(.{10})

 

 

What does expression (.{5} represents? i think i might need to update the expression in order for this to work but not sure what the expression means.

 

Thanks,

Hassim

 

 

 

4 REPLIES 4
MarqueeCrew
20 - Arcturus
20 - Arcturus

@HassimDiallo ,

 

. represents any character

 {5} qualifies it to 5, so five of anything

 () the parenthesis explains it as a group. 

cheers,

 

 mark

Alteryx ACE & Top Community Contributor

Chaos reigns within. Repent, reflect and restart. Order shall return.
Please Subscribe to my youTube channel.
MarqueeCrew
20 - Arcturus
20 - Arcturus

Left([field],5)

substring([field],5,23)

 etcetera is an alternate way. 

cheers,

 

 mark

Alteryx ACE & Top Community Contributor

Chaos reigns within. Repent, reflect and restart. Order shall return.
Please Subscribe to my youTube channel.
HassimDiallo
6 - Meteoroid

Thank you Mark. i just confirmed the expression is correct and lined up with the Data. ideally it should parsed and give me 14 separate Columns. for some reason it is not working. Is there anything i am missing  or i can do?

 

Made up Data and expression to parse:

 

0002 9999999999 0000999999 00000000 0000000000080000000 Credit USD 0000000000 99999 9000009999 0099999999 0000 0000000000000000000000 0000000000

 

HassimDiallo_0-1602858180462.png

 

HassimDiallo
6 - Meteoroid

Mark - please disregard. i got it to work. i just had to update the expression to fit my data. i accepted your solution. Thanks!

Labels