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

Compete to become Power BI Data Viz World Champion! First round ends August 18th. Get started.

Reply
sapirmarko
Helper I
Helper I

visual total not matching sum of individual row

hi,

I use with this DAX measure to get a value on matrix :

STILLS_JUICE =
var POINT= CALCULATE(MAX(SKU_Racing[ point]),SKU_Racing[tag_name]="stiils" && SKU_Racing[product_group]="JUICE")
var COUNT1 =CALCULATE(MAX(SKU_Racing[count]),SKU_Racing[tag_name]="stiils" && SKU_Racing[product_group]="JUICE")
var x=
IF(CALCULATE(DISTINCTCOUNT(Sale_Out[product_master_id]),Product_Tags[STILLS]="JUICE")>=COUNT1, POINT,BLANK())
var y = SUMMARIZE(Sale_Out,Sale_Out[creator_id],Sale_Out[outlet_id], "xx",x)
return IF(
HASONEVALUE(Sale_Out[creator_id]) && HASONEVALUE(Sale_Out[outlet_id]),x,
SUMX(y,[xx]))
I get the correct number of each line but not in total.
I did the same measure to another  Product_Tags[STILLS] ="JUICE" and I get the correct number of each line but not in total.
for the both of them I get 75 in total ( because the number of line that I get is 25 ant it's sum all the lines even if it's blank)
and I still get a mistake on the total table :
sapirmarko_0-1651577812003.png

thank you for your help!

 
1 ACCEPTED SOLUTION
mahoneypat
Microsoft Employee
Microsoft Employee

Please see this video for how to get your expected total with a reference to your existing measure.

(2) Power BI - Tales from the front #01 - Getting the Right Total - YouTube

Pat





Did I answer your question? Mark my post as a solution! Kudos are also appreciated!

To learn more about Power BI, follow me on Twitter or subscribe on YouTube.


@mahoneypa HoosierBI on YouTube


View solution in original post

4 REPLIES 4
sapirmarko
Helper I
Helper I

it's doesn't work.. maybe because I have 2 categories?

 

mahoneypat
Microsoft Employee
Microsoft Employee

Please see this video for how to get your expected total with a reference to your existing measure.

(2) Power BI - Tales from the front #01 - Getting the Right Total - YouTube

Pat





Did I answer your question? Mark my post as a solution! Kudos are also appreciated!

To learn more about Power BI, follow me on Twitter or subscribe on YouTube.


@mahoneypa HoosierBI on YouTube


I use SUMX but still I didn't get the right result

Anonymous
Not applicable

Hi @sapirmarko,

It seems like a common multiple aggregation calculation issues, you can take a look at the following blog if helps:

Measure Totals, The Final Word 

Regards,

Xiaoxin Sheng

Helpful resources

Announcements
August Power BI Update Carousel

Power BI Monthly Update - August 2025

Check out the August 2025 Power BI update to learn about new features.

August 2025 community update carousel

Fabric Community Update - August 2025

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

Top Solution Authors