Alteryx Designer Desktop Discussions

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

Combine multiple columns into single with comas

navya123
5 - Atom

 

Hi,

Case:1  I have a multiple columns I need to combine into single column with commas, Can you please suggest the best way to get the desired results. I have attached the desired output and input please check 

 

Case 2: Input

BARRETT, ORI A.
MCKEE, V.
CONRAD, NATALIE U.
VELEZ, GAVIN B.
CRAFT, UMA J.
WARNER, DANTE Y.

 

Now I need the the below as desired output.

A.ORI BARRETT 
 V.MCKEE
 U.NATALIE CONRAD
B.GAVIN VELEZ
 J.UMA CRAFT
Y.DANTE WARNER

Can you please help me to solve this both cases.

4 REPLIES 4
alexnajm
17 - Castor
17 - Castor

Here it is! I assumed you wanted Ori A. Barrett not A.Ori Barrett

Prometheus
12 - Quasar

I used a Text to Columns tool to parse the input at the comma, which created two columns -- Input1 and Input2. I then used a RegEx tool's Parse function to identify and parse the first name and middle initial in Input2. After that, I used a Formula tool to concatenate the parsed out data into your desired output. 

TTC.PNG

RegEx Parse.PNG

Expressions.PNG

Combine Mult Results.PNG

grazitti_sapna
17 - Castor

Hi navya123

By using text to column tool and then filtering you can achieve the output. Please refer attached workflow.

Thanks!

Sapna Gupta
Pilsner
10 - Fireball
 

The top flow gives the output matching your sample data however I have included a second route which changes the order based only on the comma. I hope this is helpful, let me know how you get on

Screenshot 2023-08-04 141424.png

Labels