Alteryx Designer Desktop Discussions

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

Groups of rows to columns

LiamSkop
5 - Atom

 

I have data that looks like this:

0.id09231
0.date12/3/14
0.score5-2
1.id09232
1.date13/3/14
1.score3-0
2.id09233
2.date14/3/14
2.score1-2

 

And I would like to turn it into this: 

 iddatescore
00923112/3/14 5-2
10923213/3/14 3-0
20923314/3/14 1-2

 

Would this be possible?
Thanks,

Liam

5 REPLIES 5
atcodedog05
22 - Nova
22 - Nova

Hi @LiamSkop 

 

Here is a workflow for the task.

Output:

atcodedog05_0-1604923345839.png

Workflow:

atcodedog05_0-1604923373936.png

 

Hope this helps 🙂


If this post helps you please mark it as solution. And give a like if you dont mind 😀👍

echuong1
Alteryx Alumni (Retired)

Given that your first column contains the row ID and the field name (header), you can use a text to columns to separate these. A period is the delimiter and it will be split into 2 columns.

 

From there, you can use a cross-tab to pivot the data. You would select the row ID field as a group by, so every ID will be a separate row. The second part of the field header will be the headers, and the second column of your original dataset will be the values.

 

You have to specify a method of aggregation should there be duplicates in the headers and group by fields. This won't do anything in our case since we don't have duplicates, so I just chose concatenate. 

 

Hope this helps!

 

echuong1_0-1604929150121.png

 

atcodedog05
22 - Nova
22 - Nova

Happy to help 🙂 @LiamSkop 

 

Cheers and Happy Analyzing 😀

LiamSkop
5 - Atom

Thank you so much, that does it perfectly

LiamSkop
5 - Atom

Thank you, worked like a charm

Labels