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

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

Reply
manuel_e
Frequent Visitor

% of total not calculating correctly at the row level

Hello,

I am trying to calculate the difference between "Current Quarter MS%" and "Prior Quarter MS%" but the results are not correct:
manuel_e_0-1722453361865.png

Subtotals in gray seem to be calculating correctly but at the row level, they're not. 

My calculations for Current Quarter MS% are:

manuel_e_1-1722453558539.png

My calculations for Prior Quarter MS% are:

manuel_e_2-1722453634653.png



and to obtain the difference, I have just subtacted one from the other:

manuel_e_3-1722453672444.png

But as you can see in the image above, the totals are incorrect, only the subtotals are correct.

Would you please help me?

1 ACCEPTED SOLUTION
manuel_e
Frequent Visitor

I found the solution:

I needed to use "ALL" and add the "Manufacturer" column

manuel_e_0-1722533266428.png

What this did was that it gave me the totals by subgroup (at the manufacturer level) so the results would be divided by the total of each subgroup (manufacturer) instead of the results being divided by the grand total.

View solution in original post

8 REPLIES 8
manuel_e
Frequent Visitor

I found the solution:

I needed to use "ALL" and add the "Manufacturer" column

manuel_e_0-1722533266428.png

What this did was that it gave me the totals by subgroup (at the manufacturer level) so the results would be divided by the total of each subgroup (manufacturer) instead of the results being divided by the grand total.

parry2k
Super User
Super User

@manuel_e seems like there is something else that I am missing. If possible share the file, remove any sensitive information before sharing. You can share using onedrive/google drive 



Subscribe to the @PowerBIHowTo YT channel for an upcoming video on List and Record functions in Power Query!!

Learn Power BI and Fabric - subscribe to our YT channel - Click here: @PowerBIHowTo

If my solution proved useful, I'd be delighted to receive Kudos. When you put effort into asking a question, it's equally thoughtful to acknowledge and give Kudos to the individual who helped you solve the problem. It's a small gesture that shows appreciation and encouragement! ❤


Did I answer your question? Mark my post as a solution. Proud to be a Super User! Appreciate your Kudos 🙂
Feel free to email me with any of your BI needs.

parry2k
Super User
Super User

@manuel_e @How does raw data looks like? How these tables are connected to each other? What column are you using on rows?



Subscribe to the @PowerBIHowTo YT channel for an upcoming video on List and Record functions in Power Query!!

Learn Power BI and Fabric - subscribe to our YT channel - Click here: @PowerBIHowTo

If my solution proved useful, I'd be delighted to receive Kudos. When you put effort into asking a question, it's equally thoughtful to acknowledge and give Kudos to the individual who helped you solve the problem. It's a small gesture that shows appreciation and encouragement! ❤


Did I answer your question? Mark my post as a solution. Proud to be a Super User! Appreciate your Kudos 🙂
Feel free to email me with any of your BI needs.

I have a master table that's related to the current quarter table and the prior quarter table. All of the columns are the same, and I'm using the columns from the master table and including the calculations from the other tables:

manuel_e_0-1722518544099.png

I've chosen the columns in the pivot from this master table and all calculations from the other tables. The slicers and filters are really from the master table. 
My table has three rollups:

manuel_e_0-1722520490535.png

 

I've tried using ALL, ALLSELECTED, ALLEXCEPT, a combination of ALL & others but I think I don't understand it well enough. I really just want to subtract one column from the other.

in your measure allselected should be master table 



Subscribe to the @PowerBIHowTo YT channel for an upcoming video on List and Record functions in Power Query!!

Learn Power BI and Fabric - subscribe to our YT channel - Click here: @PowerBIHowTo

If my solution proved useful, I'd be delighted to receive Kudos. When you put effort into asking a question, it's equally thoughtful to acknowledge and give Kudos to the individual who helped you solve the problem. It's a small gesture that shows appreciation and encouragement! ❤


Did I answer your question? Mark my post as a solution. Proud to be a Super User! Appreciate your Kudos 🙂
Feel free to email me with any of your BI needs.

Thank you, I have just tried it but it gave me the same result. 😞

manuel_e_0-1722521332097.png

 

parry2k
Super User
Super User

@manuel_e 

As a best practice, add a date dimension in your model and use it for time intelligence calculations. Once the date dimension is added, mark it as a date table on table tools. Check the related videos on my YT channel

 

Add Date Dimension
Importance of Date Dimension
Mark date dimension as a date table - why and how?
Time Intelligence Playlist

 



Subscribe to the @PowerBIHowTo YT channel for an upcoming video on List and Record functions in Power Query!!

Learn Power BI and Fabric - subscribe to our YT channel - Click here: @PowerBIHowTo

If my solution proved useful, I'd be delighted to receive Kudos. When you put effort into asking a question, it's equally thoughtful to acknowledge and give Kudos to the individual who helped you solve the problem. It's a small gesture that shows appreciation and encouragement! ❤


Did I answer your question? Mark my post as a solution. Proud to be a Super User! Appreciate your Kudos 🙂
Feel free to email me with any of your BI needs.

I do have a date table and they're tied to my tables.

Helpful resources

Announcements
FabCon Global Hackathon Carousel

FabCon Global Hackathon

Join the Fabric FabCon Global Hackathon—running virtually through Nov 3. Open to all skill levels. $10,000 in prizes!

October Power BI Update Carousel

Power BI Monthly Update - October 2025

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

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.