Alteryx Designer Desktop Discussions

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

Summing the rows based on condition

Nikhil86
7 - Meteor

Hi All, 

 

I am struggling to get to the solution for below scenario: 

 

I am trying to sum up the Quantity based on the combination of ID and Sub Account, 

 

Use Case: If ID and Sub Account combination is same then sum the Quantity, if the combination is not same then do not sum the Quantity as is. 

 

Input_Output.PNG

 

To achieve this I have used Summarize tool i have group by ID , Sub Account , Description and Date and used Sum on 'Quantity' but somehow its summing up the whole Quantity ( See False Output) 

 

Can anyone have any idea what I am doing wrong and what can be done to handle this? Any help is much appreciated. 

 

 

3 REPLIES 3
atcodedog05
22 - Nova
22 - Nova

Hi @Nikhil86 

 

Can you share the workflow where you are facing the issue.

Raj_Singh1
9 - Comet

Hi @Nikhil86 

Please see attached. let me know if it works for you

 

Capture6.JPG

echuong1
Alteryx Alumni (Retired)

The issue is your group by fields. You want to do the group by on ID and Sub Account. This will control what each row represents - it will be every unique combination of whatever is a group by field. From there, you'd do a sum of quantity. For Description and Date, you'd need to choose how you want to bring those values in. I suggest taking a "first" in your case.

 

echuong1_0-1605099559998.png

 

Labels
Top Solution Authors