Get Inspire insights from former attendees in our AMA discussion thread on Inspire Buzz. ACEs and other community members are on call all week to answer!

Alteryx Designer Cloud Discussions

Find answers, ask questions, and share expertise about Alteryx Designer Cloud.
SOLVED

I have one file that has a month column and a value column, and another file that has each month as it’s own column, and one row for all the values. I want to get both files into the format of the month column and value column. Can I do this?

 
2 REPLIES 2
Trifacta_Alumni
Alteryx Alumni (Retired)

In the dataset with columns for each individual month, try using the unpivot transform on all columns you would like to end up in your single date column.

 

The way the unpivot transform works is it takes the column headers in the range of columns selected, and transposes them into row values of a single key column, and takes the row values for each original column in the range of columns selected and transposes those values into a single value column. This is demonstrated below. Column1, Column2, Column3 become three rows in the key column; value1, value2, value3 become three rows in the Value column.

You can see what I mean below:

 

 

Unpivoting the above set of 3 columns, each with 1 row value, results in this:

 

 

 

Perfect, that's what I was looking for. Thanks!