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

Grand total for a measure doenst add up

Below 10% measure doesn't add up in the grand total.. Please help

Capture.PNGCapture.PNG2.PNG

1 ACCEPTED SOLUTION
Anonymous
Not applicable

My husband fixed it using below reference:

 

https://powerpivotpro.com/2012/03/subtotals-and-grand-totals-that-add-up-correctly/

 

So he added another measure below

 

=IF(COUNTROWS(VALUES('Tariffed Receipts Reporting 4'[FiscalMonthYearName]))=1,
[10%],
SUMX(VALUES('Tariffed Receipts Reporting 4'[FiscalMonthYearName]), [10%])
)

 

Now the grand total is correct

 

Capture.PNG3.PNG

View solution in original post

4 REPLIES 4
Anonymous
Not applicable

My husband fixed it using below reference:

 

https://powerpivotpro.com/2012/03/subtotals-and-grand-totals-that-add-up-correctly/

 

So he added another measure below

 

=IF(COUNTROWS(VALUES('Tariffed Receipts Reporting 4'[FiscalMonthYearName]))=1,
[10%],
SUMX(VALUES('Tariffed Receipts Reporting 4'[FiscalMonthYearName]), [10%])
)

 

Now the grand total is correct

 

Capture.PNG3.PNG

jdbuchanan71
Super User
Super User

Hello @Anonymous 

In the context of the total row [Current 10%] is not blank so your SUMX never gets [Sum of 301 Tariff value].  You need to move the IF inside the SUMX like so.

10% =
SUMX (
    VALUES ( YourTable[FiscalMonthYearName] ),
    IF ( [Current 10%] = BLANK (), [Sum of 301 Tariff value], [Current 10%] )
)

This will move the check on [Current 10%] into the iteration over  VALUES ( YourTable[FiscalMonthYearName] ).

 

You can try it with the old VALUES list just moving the if, not sure if that will give you what you want though.

10% =
SUMX (
    VALUES ( 'Tariffed Receipts Reporting 4'[List] ),
    IF ( [Current 10%] = BLANK (), [Sum of 301 Tariff value], [Current 10%] )
)
Anonymous
Not applicable

@jdbuchanan71  thanks for trying. 🙂

Glad you were able to find a solution. Smiley Happy

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.