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 Desktop Discussions

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

Vertical to Horizontal field (Cross TAB)

Inactive User
Not applicable

Hello Masters,

I need to transpose the data to horizontally  - i cannot use cross-tab or transpose or summarize to match my output. 

Kindly see attached raw data and output for your consideration.  Kindly advice how i can build a logic in Alteryx. 

Thanks - Guru

RAW DATA

GuruDB_1-1620144562818.png

OUTPUT

GuruDB_0-1620144465737.png

 

4 REPLIES 4
phottovy
13 - Pulsar
13 - Pulsar

Hi @Inactive User 

 

Here is what I put together. I renamed a couple columns to specify Account 1 or 2 in the column name but I think it gets you close to what you are looking for.

 

 

DawnDuong
13 - Pulsar
13 - Pulsar

Hi @Inactive User 

In this data structure, you actually need to create a number of outputs, and then join these outputs to create the desired output view.
- Step 1a: simple cross tab of the field [Accounts] > Grouped by 3 fields [PAY DATE], [REC. DATE], [CUSP#] > Choose aggregation method = Sum for the desired values. In this case, the desired values are columns [Calculated Amount] and [Calculated Refund]. Since you need 2 sums of values, it means you will need to have 2 cross tabs (1 for each value). 

- Step 1b: use Select Tool to rename the columns of the output from the Cross tab tool

Sub account 1NRASub Account 2NRA

- Step 2a: simple sum to get the total payment and NRA by [PAY DATE], [REC. DATE], [CUSP#]. Only 1 sum tool is needed.

- Step 2b: use Select Tool to rename the columns of the output from the Sum tool

PAYMENTNRA W/H

 

- Step 3a: use join tool to join the outputs from 2a and 2b

- Step 3b: Use Formula tool to calculate 

TOTAL NRAREFUND

- Step 4: to add the row on top to show the month > there can be a number of different ways to do this, by Reporting Tool or other method. 

 

Hopefully the schematic flow above helps you get the desired outcome and is useful in your next tasks involving Alteryx.

 

Happy solving.

Dawn.

 

Inactive User
Not applicable

Thanks so much for your guidance. 

Inactive User
Not applicable

@phottovy Thanks so much for your guidance. 

Labels