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
lburgess
Helper II
Helper II

Calculating % of total

I'm trying to calculate the % of an item within a sub-category.  The table contains the following columns:

 

Category

SubCategory

Period (date)

Amount

 

A snippet of the report looks like this.

lburgess_1-1651094490308.png

 

My challenge is to get the Amount % to be the % of the amount within a particular category (ex. Type) and month.  
For the "Source" category, all of the Amount % should be 100%.

For "Type", the percentages should be the Subtype (e.g. Conventional) divided by the sum of the Amounts within that Category.

 

The calculation of Amount % is 

Amount % =
VAR CurrentCategory = VALUES(vw_ChaseAudit[Category])
VAR CurrentSubCategory = VALUES(vw_ChaseAudit[SubCategory])
VAR AmountForCurrentSelection = SUM(vw_ChaseAudit[Amount])
VAR TotalAmount =
SWITCH(
TRUE(),
ISINSCOPE(vw_ChaseAudit[TextDate]),CALCULATE(SUM(vw_ChaseAudit[Amount]),ALLSELECTED(vw_ChaseAudit),vw_ChaseAudit[Category] IN CurrentCategory),
ISINSCOPE(vw_ChaseAudit[SubCategory]),CALCULATE(SUM(vw_ChaseAudit[Amount]),ALLSELECTED(vw_ChaseAudit),vw_ChaseAudit[Category] IN CurrentCategory),
ISINSCOPE(vw_ChaseAudit[Category]),CALCULATE(SUM(vw_ChaseAudit[Amount]),ALLSELECTED(vw_ChaseAudit))
)
RETURN
IF(
ISINSCOPE(vw_ChaseAudit[Category]),
DIVIDE(AmountForCurrentSelection,TotalAmount),
1
)

 

 

2 REPLIES 2
Ashish_Mathur
Super User
Super User

Hi,

Share the download link of your PBI file and show the expected result clearly.


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

I can't share the link. The data source is an in-house database. 

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.