Alteryx Designer Desktop Discussions

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

Adding up Columns

Sophie95
8 - Asteroid

Help! How do I add up column data and place totals  at the bottom of each column. I tried the summarize tool. My column data type is Int64. I attached a sample of my workflow data.

 

Thank you!

6 REPLIES 6
Inactive User
Not applicable

Summarise tool to get totals, then you need to add the dimensional plug values like Total Region, etc. into the appropriate columns using a formula tool. Then once it mimicks the original structure union it back on and place it in 2nd order in the union options.

Sophie95
8 - Asteroid

Thank you, I am a bit lost. I have summarized by data already. I am not sure how to do the next step you recommended.

Inactive User
Not applicable

The formula step avoids having needless nulls in your data when you union the totals back on; you can use it to plug null values where the original data structure would have natural column values. Just put a union tool and connect both streams together to understand what I am conveying.

derekbelyea
12 - Quasar

 

 

Hi Sophie

 

This will get you close to the answer you are looking for:

 

 

 

Summarizing and SortingSummarizing and Sorting

danilang
19 - Altair
19 - Altair

Hi @Sophie95 

 

Here's a workflow that demonstrates what @Inactive User was referring to

 

WF.png

The top branch generates the grand total and appends it the existing dataset.  The bottom branch does the same with the subtotals, but uses a RecordID trick to get the subtotals in the correct place.  The Summarize tools gets the max record ID for each region and then adds .5 to this to ensure that the subtotal rows follow the corresponding regions.  These records are then appended the result of the top branch.  The 2 text inputs add in the table names. 

 

The solution is dynamic in that it will handle any number of sub-regions without having to explicitly specify them in separate filter tools.

 

The result are as follows

 

Results.png 

 

Note that the percentages are displayed as decimals, since this the way they were read from the input file.   

 

Dan

Sophie95
8 - Asteroid

Thank you very much for your help Derekbelyea!  I am still very new to the tool, just polishing up my first workflow. 

Labels