Hi everyone!
I am trying to replicate a SumIF (i guess) in Alteryx.
As you can see in the picture, I have in the first column an Item Code, in the third a number representing a transaction quantity and in the fifith the total quantity after the transaction.
I want to create a new column with the sum of all the transaction quantities for any give item code. For example, for the item in the picture I want to have a new column that, for each of the 7 rows with that Item Code, shows the results of all the transactions in the third column (49 in this case)
Do you now how I can replicate this in alteryx knowing for any given item I might have from 2 to potentially infinite transactions?
Thank you for your help!
Solved! Go to Solution.
Use the summarize tool to create your totals grouped on item code. Then join this with your original table (using the item code).
Hi Martin,
thank you for your help. It worked perfectly but with three exceptions
For three items with transaction history that looks like this (final transaction is negative) the tool gives me 4 rather than 2 as a result.
I set the tool in this way:
Do you have any clue with these three items are acting like this?
Thanks!
I would add a Count into the summarize tool - to check it is adding all 5 Transaction Quantities together.
My thought is that there may be leading spaces on some of the item codes. Adding the count would highlight this.