Looking for some help with the Multi-Field Formula tool in Alteryx. I am trying to apply a calculation to multiple columns.
Example:
Data is structured in columns. I need to calculate (multiply by 0.5) to get 50% of the value listed in each column.
ID | Description | A | B | C | D | E | F |
74521 | Mickey M. | 500 | 500 | 500 | 500 | 500 | 500 |
72673 | Minnie M. | 1000 | 2500 | 600 | 4400 | 1200 | 300 |
77342 | Goofy | 100 | 420 | 640 | 1200 | 346 | 232 |
75932 | Donald D. | 1410 | 3240 | 822 | 642 | 2410 | 360 |
74385 | Daisy D. | 100 | 100 | 100 | 100 | 100 | 100 |
I am expecting the following result:
ID | Description | A | B | C | D | E | F |
74521 | Mickey M. | 250 | 250 | 250 | 250 | 250 | 250 |
72673 | Minnie M. | 500 | 1250 | 300 | 2200 | 600 | 150 |
77342 | Goofy | 50 | 210 | 320 | 600 | 173 | 116 |
75932 | Donald D. | 705 | 1620 | 411 | 321 | 1205 | 180 |
74385 | Daisy D. | 50 | 50 | 50 | 50 | 50 | 50 |
Can someone help me with the syntax on how to configure the tool for this type of result? I am new to this tool, and would appreciate the help.
Thanks!
Solved! Go to Solution.
Perfect! I just needed a little help and this was spot on!
Thanks for your quick response. Much appreciated.
Is it possible to SUM all the rows together and create a new row? Ultimately I would like to add all the rows together before using the multi-field formula. I would use the Summarize tool, but I have to manually add all the columns, which in my real world data is a lot. Just looking for another way to sum all the numeric rows into a single row on multiple columns of data.
Hi @lmaughan,
I am not sure if I got that right, but you want to build the sum of all columns BEFORE dividing them by 2? If not, just use the outgoing connection after the Multi-Field Tool for the Transpose Tool.
I used @JosephSerpis workflow as a base and fixed the Multi-Field Tool because it was also dividing the ID column.
What happens:
1) Transpose Tool to shift all columns into rows
2) Select Tool to fix data type (I don't know why they were not recognized as numbers)
3) Summarize Tool for the sum
4) Join to bring everything back together
Workflow attached.
Best
Alex