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
Anonymous
Not applicable

Total Column Sum is not equal

Hi everyone! I've been stuck with this, hope you can help me. Thanks! The Total Sum should be 475.

 

 
 
 

Capture.PNG

1 ACCEPTED SOLUTION

Hi @Anonymous ,

 

We suggest you to delete your shared report link in your reply if it contain any confidential information, We can also use the following measure to meet your requirement:

 

B2B OUTLET BUYING =
SUMX (
    DISTINCT ( 'SUB TYPES'[Tag] ),
    CALCULATE (
        DISTINCTCOUNT ( [Outlet Name] ),
        'TOTAL SALES DATA'[Billing Type] = "ZRSS"
    )
)


Best regards,

 

Community Support Team _ Dong Li
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

15 REPLIES 15
amitchandak
Super User
Super User

Share the formula you are using as of now.

Share with Power BI Enthusiasts: Full Power BI Video (20 Hours) YouTube
Microsoft Fabric Series 60+ Videos YouTube
Microsoft Fabric Hindi End to End YouTube
Anonymous
Not applicable

B2B OUTLET BUYING = CALCULATE(DISTINCTCOUNT([Outlet Name]),'TOTAL SALES DATA'[Billing Type]="ZRSS") Here

DISTINCTCOUNT() counts the unique values. In your total, it counts the unique values in [Outlet Name] in the current filter context which is [Billing Type]="ZRSS" and two or more tags may be sharing the same Outlet Name and that Outlet Name is counted as one only in the total. 





Dane Belarmino | Microsoft MVP | Proud to be a Super User!

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


"Tell me and I’ll forget; show me and I may remember; involve me and I’ll understand."
Need Power BI consultation, get in touch with me on LinkedIn or hire me on UpWork.
Learn with me on YouTube @DAXJutsu or follow my page on Facebook @DAXJutsuPBI.
Anonymous
Not applicable

Hi danextian,

Ohhh. I get it. Is the a way to fix this? I need to count distinct outlets with the billing type of ZRSS. Row values are correct its just that the total of the column did not match to the individual values in the rows.

Thanks

Hi @Anonymous ,

 

You may try @Anonymous 's formula. SUMMARIZE() creates a virtual table of count of unique outlet name for each tag  within the measure itself and SUMX sums up the count. Or you may create a calculated column that concatenates tag and outlet name columns and use that in your distinctcount measure instead. 





Dane Belarmino | Microsoft MVP | Proud to be a Super User!

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


"Tell me and I’ll forget; show me and I may remember; involve me and I’ll understand."
Need Power BI consultation, get in touch with me on LinkedIn or hire me on UpWork.
Learn with me on YouTube @DAXJutsu or follow my page on Facebook @DAXJutsuPBI.

Can you also share your data model?  What is [Outlet Name]?  By convention, it should be a measure but I am not sure it is.

 

Thanks!

DAwn

 

Anonymous
Not applicable

Here,

 

 

Hi @Anonymous ,

 

We suggest you to delete your shared report link in your reply if it contain any confidential information, We can also use the following measure to meet your requirement:

 

B2B OUTLET BUYING =
SUMX (
    DISTINCT ( 'SUB TYPES'[Tag] ),
    CALCULATE (
        DISTINCTCOUNT ( [Outlet Name] ),
        'TOTAL SALES DATA'[Billing Type] = "ZRSS"
    )
)


Best regards,

 

Community Support Team _ Dong Li
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Anonymous
Not applicable

Hi @v-lid-msft ,

 

Noted on the deletion of link.

 

And thank you! The formula works. Thank you very much

 

Rey

Anonymous
Not applicable

Try this NewMeasure = SUMX(SUMMARIZE('TOTAL SALES DATA','SUB TYPES'[Tag],"total",[B2B OUTLET BUYING]),[total])

The issue you faced because of incorrect parenthesis.

Thanks
Pravin
Anonymous
Not applicable

Try the measure which i have corrected.
Anonymous
Not applicable

Try this
Sumx(summerize(table,table[column]"total",[b2b outlet]),[total])

Thanks,
Pravin
Anonymous
Not applicable

Hi, I'm sorry, I'm very new at Power Bi.

 

Can I send the link of my dashboard instead?

Anonymous
Not applicable

Go to power bi desktop

Click on home then click on meausre
Write the above dax
And add that measure and required column to table visual.


Note :change the column and table names as per requirement.
Anonymous
Not applicable

NewMeasure = SUMX(SUMMARIZE('TOTAL SALES DATA','SUB TYPES'[Tag],"total",[B2B OUTLET BUYING],[total]))
 
result was "Too few arguments were passed to the SUMX function. The minimum argument count for the function is 2."

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.