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

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more

Reply
admin11
Memorable Member
Memorable Member

My Vari % return wrong Total summary % , How to correct it ?

Hi All

 

_Vari_%_NP = if(isblank( divide(
[_YTD_NP_SGD]
-
[_LYTD_NP_SGD]
,
[_LYTD_NP_SGD]
)),1, divide(
[_YTD_NP_SGD]
-
[_LYTD_NP_SGD]
,
[_LYTD_NP_SGD]
))
 
 

admin11_0-1620478987697.png

My PBI file :-

https://www.dropbox.com/s/0ln5k19oj4i8cfp/PBT_V2021_400%20GL_TI.pbix?dl=0

 

Paul

1 ACCEPTED SOLUTION
Anonymous
Not applicable

HI @admin11,

It seems like a common calculation issue when you try to apply multiple aggregates on measure expression.

For this scenario, you can take a look at the below blog about measure calculation on the total level.

Measure Totals, The Final Word 

BTW, we do not so recommend you to nested multiple measures in one calculation, they may conflict with the calculation when different formulas calculate on current row contents.

Optimizing DAX expressions involving multiple measures - SQLBI
Regards,
Xiaoxin Sheng

View solution in original post

2 REPLIES 2
Anonymous
Not applicable

HI @admin11,

It seems like a common calculation issue when you try to apply multiple aggregates on measure expression.

For this scenario, you can take a look at the below blog about measure calculation on the total level.

Measure Totals, The Final Word 

BTW, we do not so recommend you to nested multiple measures in one calculation, they may conflict with the calculation when different formulas calculate on current row contents.

Optimizing DAX expressions involving multiple measures - SQLBI
Regards,
Xiaoxin Sheng

MFelix
Super User
Super User

Hi @admin11 ,

 

First of all you can use the COALESCE to make the value for the non blank values:

MFelix_0-1620484251625.png

In second place if you look at the totals you have the correct percentage calculated:

 

369.94 - (-155.336,66) = 155.706,60

 % =  155.706,60 / -155.336,66 = -1,0023 * 100 = -100.23%

 

Since you are rounding it gives -100%.

 

What is the value you need to have on the totals is it the sumx of the percentages?


Regards

Miguel Félix


Did I answer your question? Mark my post as a solution!

Proud to be a Super User!

Check out my blog: Power BI em Português



Helpful resources

Announcements
Power BI DataViz World Championships

Power BI Dataviz World Championships

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!

December 2025 Power BI Update Carousel

Power BI Monthly Update - December 2025

Check out the December 2025 Power BI Holiday Recap!

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.