Forum Discussion
Total values nor working correctly
Hi all
I created a few measures to calculate the total costs (initial and final) and savings (difference between final and initial), however I am not getting the right values as seen below:
The values surrounded in red is giving a total of zero and the values surrounded in black is giving $32,297 MM (same as the Cost tons initial) which both are incorrect.
For the second table above, I am filtering by brand "XXX".
The correct values should be the ones when I export the second table:
I tried combining summarize + sumx in my cost formulas, but it doesnt seem to work well.
How can I get my measures to work?
I attach pbix
https://1drv.ms/u/s!ApgeWwGTKtFdh0fzZlafmlA_W5kY?e=jUjru0
Thanks all!
Hi, o59393
Thank you for your feedback.
I am not sure whether I am proceeding to the right path, but please check the below picture and the link.
Cost Tons final total fix = SUMX('Query1 (3)', [Cost Tons final])Hi, My name is Jihwan Kim.
If this post helps, then please consider accept it as the solution to help other members find it faster, and give a big thumbs up.
Linkedin: linkedin.com/in/jihwankim1975/
Twitter: twitter.com/Jihwan_JHKIM
6 Replies
- Jihwan_KimSuper User
Hi, o59393
I am not sure whether I understood your question correctly, but please try the below measure.
Savings = SUMX( 'Query1 (3)',[Cost Tons initial] - [Cost Tons final])Hi, My name is Jihwan Kim.
If this post helps, then please consider accept it as the solution to help other members find it faster, and give a big thumbs up.
Linkedin: linkedin.com/in/jihwankim1975/
Twitter: twitter.com/Jihwan_JHKIM
- o59393Post Prodigy
Hi Jihwan_Kim
Almost!
The only thing not working is the total for "Cost Tons Final"
The correct total should be = $31.405 millions (you can export the table to csv to verify)
I dont know why is summing incorrectly, but it seems to be taking the false statement and not the true one.
Thanks!
- Jihwan_KimSuper User
Hi, o59393
Thank you for your feedback.
I am not sure whether I am proceeding to the right path, but please check the below picture and the link.
Cost Tons final total fix = SUMX('Query1 (3)', [Cost Tons final])Hi, My name is Jihwan Kim.
If this post helps, then please consider accept it as the solution to help other members find it faster, and give a big thumbs up.
Linkedin: linkedin.com/in/jihwankim1975/
Twitter: twitter.com/Jihwan_JHKIM