Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
Anonymous
Not applicable

Need urgent help, Incorrect measure totals

Hi community,

 

I have been struggling with this for a while, hope someone can help me out..

Following is the snapshot of my measure totals that are incorrect(higlighted in yellow):total.PNG

I tried a workaround using hasonefilter & Allexcept on one of the incorrect measures, this time it gives cumulative totals and no row subtotal as following:cumulative total.PNG

I want just the totals(not cumulative) and a correct subtotal.

My PBI is attached:

https://1drv.ms/u/s!Ag919_pO_UKrdZt7uM4Bkx2JrAY?e=7LPVBD

 

Please help,

Many thanks in advance.

 

 

2 REPLIES 2
v-xicai
Community Support
Community Support

Hi @Anonymous ,

 

You can add SUMMARIZE and SUMX function in your formula, take the measure [Difference] as example, change it like DAX below, do the same with [Fortnightly Payment] and other measures, just change the red parts of formula.

 

Difference =
var d= [Total_Billing]- [Tot fortnightly payment]    --[Difference] original formula
var _table = SUMMARIZE('Dim week ending_new', 'Dim week ending_new'[Empcost_period end dt],"_Value", d)
return IF(HASONEVALUE('Dim week ending_new'[Empcost_period end dt]), d, SUMX(_table,[_Value]))

Best Regards,

Amy

 

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Anonymous
Not applicable

Thanks @v-xicai for your solution. I used the suggested DAX to calculate Grand Difference:

 

Difference =
var d= [Total_Billing]- [Tot fortnightly payment]    --[Difference] original formula
var _table = SUMMARIZE('Dim week ending_new', 'Dim week ending_new'[Empcost_period end dt],"_Value", d)
return IF(HASONEVALUE('Dim week ending_new'[Empcost_period end dt]), d, SUMX(_table,[_Value]))

But the Measure total is still incorrect as following:

 

Capture_difference.PNG

 

Any more suggestions?

 

Thanks,

Meena

 

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

Find out what's new and trending in the Fabric Community.