Alteryx Designer Desktop Discussions

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

Freezing first line columns to rows

Lauritsjust
7 - Meteor

Hi all

I am trying to "freeze" the first column and move other columns to a new row with the frozen column as an account identifier in the first line. 

 

My input looks something like this:

Lauritsjust_3-1643712100764.png

 

and I would like my output to look like this:

Lauritsjust_2-1643712084122.png

 

 

However, when I do it, it keeps putting the new rows in different columns instead of column 2-4.

 

Any suggestions? 

12 REPLIES 12
messi007
15 - Aurora
15 - Aurora

@Lauritsjust,

 

Please see below :

 

messi007_0-1643712969921.png

 

Attached the workflow,

 

Hope this helps!

Regards

Ben_H
11 - Bolide

Hi @Lauritsjust,

 

This is the way I would approach it -

 

Ben_H_0-1643712992329.png

I transposed the data, and then removed the numbers from the field names (ISIN1,2,3), tidied up the data a little and then cross tabbed back to the format you want.

 

Ben_H_1-1643713093307.png

 

Sorry for the brief explaination, I'm short of time - It should be pretty easy to follow if you download the attachment.

 

Regards,

 

Ben

 

atcodedog05
22 - Nova
22 - Nova

Hi @Lauritsjust 

 

Here is a dynamic solution that would accommodate n columns.

Workflow:

atcodedog05_0-1643713158245.png

 

Hope this helps : )

 

Lauritsjust
7 - Meteor

Thanks for the reply. Even though it is a good solution, I might need to rephrase the question.

I forgot to mention that I have more than 500 columns so the solution provided would be very time consuming.

Do you have an idea for a solution to this problem?

atcodedog05
22 - Nova
22 - Nova

Hi @Lauritsjust 

 

Solutions provided by me and @Ben_H are the ideal ways of solving this. There is no other dynamic method.

 

Mine would be slightly faster than I am using multi-row formula instead of the tiles tool.

 

atcodedog05_0-1643713668196.png

 

@Lauritsjust updated it with screenshot

 

Hope this helps : )

Lauritsjust
7 - Meteor

This is it, but when applying the solution to the data I realized that i made a mistake when creating the test input:

This is more fitting

Lauritsjust_0-1643713673727.png

 

Is there a way to name column 2+n*3 to ISINn and column 3+n*3 to AMOUNTn and so fourth? This would make the solution usable.

OllieClarke
15 - Aurora
15 - Aurora

Hey @Lauritsjust 

here's a solution which should scale if you get more columns added:

OllieClarke_0-1643713844573.png

 

Lauritsjust
7 - Meteor

This is it, but when applying the solution to the data I realized that i made a mistake when creating the test input:

This is more fitting

Lauritsjust_0-1643713933492.png

 

 

Is there a way to name column 2+n*3 to ISINn and column 3+n*3 to AMOUNTn and so fourth? This would make the solution usable.

OllieClarke
15 - Aurora
15 - Aurora

Hey @Lauritsjust 

This version will take the headers dynamically from their order (assuming 1 is always account).

Labels
Top Solution Authors