Bring your best ideas to the AI Use Case Contest! Enter to win 40 hours of expert engineering support and bring your vision to life using the powerful combination of Alteryx + AI. Learn more now, or go straight to the submission form.
Start Free Trial

Alteryx Designer Desktop Discussions

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

Sum Check Between an Ex_ID & Amount

ethankutch
7 - Meteor

Hello,

 

I am currently trying to put in a check that will essentially allow me to recognize if amounts are somehow missing from my data/workflow.

 

As of right now, my External ID field has the sum of the total amounts that go along with that payment date, within the actual ID. These sums are identifiable as they come right after the dash in each External ID.

 

What I am trying to figure out is how to Sum each amount that corresponds to the correct external ID & payment date and make sure that all those amounts sum up and match the amount that is within the External ID

 

For Instance, the sum of Amounts 6622+4800+3600+3000 should equal 18022, as seen in the External ID.

 

The catch is also I need Alteryx to recognize when to start a new summation, when the External ID changes. Any suggestions?

 

Thanks!

 

See attached image for context.

4 REPLIES 4
caltang
17 - Castor
17 - Castor

Not sure if I understand you wholly, but can't you use a Summarize Tool that sums up the column for value? Then use REGEX to get the last values of your external ID, and match them with a filter tool. If they don't match, then it comes out.

Calvin Tang
Alteryx ACE
https://www.linkedin.com/in/calvintangkw/
caltang
17 - Castor
17 - Castor

I think the first order of business is to get the amount out of the string, so then you can compare. I've done a part of it for you, use the same idea to get the amount out, then use the Summarize tool by grouping the string and sum the values, then use the Join tool to join back to the main data and compare against the total amount. Use a Filter tool to split out those that don't match, then you have your way of checking complete.

 

If you have null values in your values, then you need to use a Data Cleansing tool to replace them with 0 so that you can apply mathematical functions on the values, otherwise it will not work as intended.

Calvin Tang
Alteryx ACE
https://www.linkedin.com/in/calvintangkw/
caltang
17 - Castor
17 - Castor

If the above is too difficult to follow, perhaps you can share some sample data with us here, then we showcase further.

 

Hope this helps.

Calvin Tang
Alteryx ACE
https://www.linkedin.com/in/calvintangkw/
ethankutch
7 - Meteor

Hey caltang,

 

Thanks so much for your help so far. A further showcase would be great. I think I understand how you can pull the amount from External ID, but am still confused about how to implement it so would restart the summing when the External ID changes (in essence checking each External ID so that sum of amounts checks out).

 

Here's some sample data and a copy of the workflow I have so far. 

 

Labels
Top Solution Authors