Alteryx Designer Desktop Discussions

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

Split a column based on a pattern of values as a delimiter?

qasdxx
7 - Meteor

I have the following data included in my first row:

 

Pan, Dongning,Mao, Chunxiao,Wang, Yong-Xu

 

I would like to split each of the names into separate columns (Pan, Dongning -- Mao, Chunxiao -- Wang, Yong-Xu)

 

I am noticing that the unique identifier is a comma followed by no space. Is it possible to use this as delimiter. For example, can I use the text to columns tool to specify that I want to split the text only if there is a comma followed by no space? 

1 REPLY 1
AngelosPachis
16 - Nebula

Hi @qasdxx ,

 

I think you can achieve this but it's not that straight forward with a text to columns tool. A regex tool configured to tokenize might work better.

 

AngelosPachis_0-1625458297003.png

 

I'm no RegEx expert, but this expression seems to be doing what you are after.

 

(\w+,\s\w+),?

 

Cheers,

 

Angelos

Labels