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
guyclewlowi2
Frequent Visitor

Accumulating subtotals

Is it possible to add accumulating sub totals into a matrix table in Power BI. So for example Income, cost of sales and then a subtotal called gross profit, then overheads and another subtotal called net profit. The net profit would be a calculation of gross profit + overheads and not just total the overheads

1 ACCEPTED SOLUTION

Hi @guyclewlowi2,

 

>>So for example Income, cost of sales and then a subtotal called gross profit, then overheads and another subtotal called net profit. The net profit would be a calculation of gross profit + overheads and not just total the overheads

Power bi not support these feature, you should write measures to calculate for these calculations and drag them to values field.

 

Regards,

Xiaoxin Sheng

Community Support Team _ Xiaoxin
If this post helps, please consider accept as solution to help other members find it more quickly.

View solution in original post

9 REPLIES 9
Ashish_Mathur
Super User
Super User

Hi,

 

This can be done in Excel using CUBE functions.


Regards,
Ashish Mathur
http://www.ashishmathur.com
https://www.linkedin.com/in/excelenthusiasts/

These each would be written as separate measures(i.e. [Income], [Cost of Sales], and [Gross Profit]), then in your matrix you would use the new "show measures on rows" formatting feature to get the layout you're describing.





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

Proud to be a Super User!




v-shex-msft
Community Support
Community Support

Hi @guyclewlowi2,

 

For your scenario, I think you can keep the original table structure to build a sample file with some fake data , then share it here.

 

Regards,

Xiaoxin Sheng

Community Support Team _ Xiaoxin
If this post helps, please consider accept as solution to help other members find it more quickly.

Please see below a link to the power BI example table and the example data

 

Sample BI table

 

Sample transactions

Hi @guyclewlowi2,

 

>>So for example Income, cost of sales and then a subtotal called gross profit, then overheads and another subtotal called net profit. The net profit would be a calculation of gross profit + overheads and not just total the overheads

Power bi not support these feature, you should write measures to calculate for these calculations and drag them to values field.

 

Regards,

Xiaoxin Sheng

Community Support Team _ Xiaoxin
If this post helps, please consider accept as solution to help other members find it more quickly.
hemantsingh
Helper V
Helper V

Can you provide some sample data so that we can have better understanding towards result formulation?

 

Regards,

Hemant

Hi Hemant,

 

Thanks for replying to the post, because its company financial data I cant share but it is typical nominal ledger transactions (in this case from SAGE 50)

You can obviously mask the data & provide us for our understanding towards its structure & the result you want to replicate out of it.

Regards

Or use https://www.mockaroo.com/ to make some fake sample data that has the same structure.





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

Proud to be a Super User!




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.