Forum Discussion

MP-iCONN's avatar
MP-iCONN
Resolver I
4 years ago
Solved

Invoice Line Amount incorrect when using SUM

Here is a weird one.  I am doing a basic Total Invoice Line Amount for example for that last two days.

 

If I do not SUM the amount I can see that all the values returned will add up to the correct amount but once I SUM it the amount is sometimes 1.5 times the amount or more.

 

Example when not sum:

Same data but now right clicked on Invoice Line Amount in the visualization and changed to SUM:

 

 

Any help with this is greatly appreciated.

 

Thank you.

  • MP-iCONN I guess in the first image you don't have any aggregation, it is possible that there are rows with the same value on the same date, and in that case, it will only show one row and when you use aggregation (SUM in 2nd image), it sums all the rows and it looks like the wrong sum.

     

    If you add another column (say same invoice date column) in the 1st image and change its aggregation to count, you will find out what rows has more than one row and you will get your answer.

     

    Follow us on LinkedIn

     

    Check my latest blog post The Power of Using Calculation Groups with Inactive Relationships (Part 1) (perytus.com) I would  Kudos if my solution helped. 👉 If you can spend time posting the question, you can also make efforts to give Kudos to whoever helped to solve your problem. It is a token of appreciation!

     

    Visit us at https://perytus.com, your one-stop-shop for Power BI-related projects/training/consultancy.

1 Reply

  • MP-iCONN I guess in the first image you don't have any aggregation, it is possible that there are rows with the same value on the same date, and in that case, it will only show one row and when you use aggregation (SUM in 2nd image), it sums all the rows and it looks like the wrong sum.

     

    If you add another column (say same invoice date column) in the 1st image and change its aggregation to count, you will find out what rows has more than one row and you will get your answer.

     

    Follow us on LinkedIn

     

    Check my latest blog post The Power of Using Calculation Groups with Inactive Relationships (Part 1) (perytus.com) I would  Kudos if my solution helped. 👉 If you can spend time posting the question, you can also make efforts to give Kudos to whoever helped to solve your problem. It is a token of appreciation!

     

    Visit us at https://perytus.com, your one-stop-shop for Power BI-related projects/training/consultancy.