Hey All! New to Alteryx, and SO THANKFUL for this board for all of the wonderful solutions people post.
Group | A | B | C | New |
1 | 643 | 324 | 896 | (A+B) |
2 | 753 | 951 | 654 | (B+C) |
3 | 789 | 516 | 713 | (A+C) |
I have a group of data wherein there's one column that defines the row as part of a single group of product. I then have columns with various attributes that I need to sum, but I need to sum different attributes specific to the product (example "New" column). I'd need all of the rows with "1" in the group column to add the "A" and "B" values in the new column, and all rows with "2" in the group column to add the "B" and "C" values in the same column, etc.
What tool is best suited for this?
Thank you!
Solved! Go to Solution.
You could accomplish this with the formula tool using an IF statement. For example:
IF [Group] = 1
THEN [A] + [B]
ELSEIF [Group] = 2
THEN [B] + [C]
ELSEIF [Group] = 3
THEN [A] + [C]
ELSE Null()
ENDIF
Hi @ijurgensen — A "Formula" tool could be your friend:
IF [Group] = 1 THEN
[A]+[B]
ELSEIF [Group] = 2 THEN
[B]+[C]
ELSEIF [Group] = 3 THEN
[A]+[C]
ELSE
Null()
ENDIF
@ijurgensen — If this solves your issue please mark the answer "Solved" or "Solved" with a Like, if not let me know!
This will help other users find the same answer/resolution. Thank you!
@ijurgensen — Thank you!