Starting December 3, join live sessions with database experts and the Microsoft product team to learn just how easy it is to get started
Learn moreGet certified in Microsoft Fabric—for free! For a limited time, get a free DP-600 exam voucher to use by the end of 2024. Register now
Hi, I have a measure which gives me the correct value for the grand total but when I try splitting it down into subtotals, the sum of the subtotals becomes greater than the grand total. I'm fairly sure that I'm messing something up w.r.t. the filter context but I'm fairly new to DAX and I can't find the error.
I have these two measures set up to calculate the LTM sum of my sales, meaning that for every month I want to calculate the total sales in that month and the previous 11 months. Pretty simple for historical months but in the current month I want to add my forecasted numbers to my actuals and in future months I want to show the forecasted numbers. These are the measures:
I hope my explanation makes sense. Anyway, I've checked and I get the correct LTM totals when using these measures UNTIL I try to create a visual that splits the total sales amount, for example by customer segment or product type.
The total at the bottom is the correct number, however the sum of the subtotals is 343,645,368 (not USD fyi)
Any ideas on how to fix this? Let me know if I need to provide more information 🙂
Solved! Go to Solution.
Just wanted to add that I've resolved the issue, it was pretty simple: when looking at the totals I either under/overshoot my forecast and the LTM reflects that, however when I split the actuals and forecasted numbers I can underperform in some categories while overperforming in others and the MAX() function then makes the sum of the subtotals larger than the "grand total".
Greate job!
Just wanted to add that I've resolved the issue, it was pretty simple: when looking at the totals I either under/overshoot my forecast and the LTM reflects that, however when I split the actuals and forecasted numbers I can underperform in some categories while overperforming in others and the MAX() function then makes the sum of the subtotals larger than the "grand total".
Starting December 3, join live sessions with database experts and the Fabric product team to learn just how easy it is to get started.
March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount! Early Bird pricing ends December 9th.
User | Count |
---|---|
94 | |
92 | |
82 | |
71 | |
49 |
User | Count |
---|---|
143 | |
121 | |
112 | |
58 | |
57 |