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

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

Reply
davebourgeois87
Frequent Visitor

How to create measure using a specific column value as the denominator

Hello,

 

I'm still pretty new to Power BI and I'm having a ton of trouble understanding filter functions in DAX. Example:

 

davebourgeois87_0-1650297792060.png

 

The above table is an example where I want to create a measure "% of HH's", which I have done successfully. However, I want to then index the values to the total line (Total Panel in example above). I tried creating a measure that returns the Total Panel value, but I can't use that as a denominator for the other values in the column because of filtering. What I want to happen is something like the below from Excel:

 

davebourgeois87_1-1650298042260.png

 

Here is my current calculation: 

% HH Index = var denom = CALCULATE([Demo % of Total HH's],'Sheet1'[DEMOS]="Total Panel")

return [Demo % of Total HH's]/denom*100

 

Any help is greatly appreciated!

 

 

1 ACCEPTED SOLUTION
ribisht17
Super User
Super User

Hello,

 

Are you looking for something like this,

 

ribisht17_0-1650357927315.png

 

Note: Divide is the name of the sheet that I have

Please use this calculation to achieve the same

Solution 2 = SUM('Divide'[% of Total HH's]) / CALCULATE(MAX('Divide'[% of Total HH's]),ALL('Divide'),'Divide'[DEMOS]="Total Panel",'Divide'[PROD]=MAX('Divide'[PROD]))
 
Regards,
Ritesh,
Mark my post as a solution if it helped you| Gentlemen & Ladies|Munde and Kudis| I like your Kudos!! !!
My You Tube Channel !! Connect on Linkedin || Power BI for Tableau Users 

View solution in original post

6 REPLIES 6
ribisht17
Super User
Super User

Hello,

 

Are you looking for something like this,

 

ribisht17_0-1650357927315.png

 

Note: Divide is the name of the sheet that I have

Please use this calculation to achieve the same

Solution 2 = SUM('Divide'[% of Total HH's]) / CALCULATE(MAX('Divide'[% of Total HH's]),ALL('Divide'),'Divide'[DEMOS]="Total Panel",'Divide'[PROD]=MAX('Divide'[PROD]))
 
Regards,
Ritesh,
Mark my post as a solution if it helped you| Gentlemen & Ladies|Munde and Kudis| I like your Kudos!! !!
My You Tube Channel !! Connect on Linkedin || Power BI for Tableau Users 

@ribisht17 Yes, this is great, thanks so much!

ribisht17
Super User
Super User

Please share your data-set, it is difficult to solve like this

 

How do I know about this Sheet1'[DEMOS]="Total Panel") ?

 

Regards,

Ritesh

Hi @ribisht17 

 

Here is a relevant data set:

 

PRODDEMOS% of Total HH's
DDTotal Panel84.20%
DDGen Z (18-29) with kids under 685.80%
DDMillennial (30-39) with kids under 680.60%
DDGen X (40-54) with kids under 671.90%
DD Brand 1Total Panel33.50%
DD Brand 1Gen Z (18-29) with kids under 637.00%
DD Brand 1Millennial (30-39) with kids under 633.00%
DD Brand 1Gen X (40-54) with kids under 626.00%
DD Brand 2Total Panel28.90%
DD Brand 2Gen Z (18-29) with kids under 635.70%
DD Brand 2Millennial (30-39) with kids under 633.80%
DD Brand 2Gen X (40-54) with kids under 631.50%
DD Brand 3Total Panel50.00%
DD Brand 3Gen Z (18-29) with kids under 654.60%
DD Brand 3Millennial (30-39) with kids under 647.70%
DD Brand 3Gen X (40-54) with kids under 639.20%

 

My apologies, but I don't think I can share the actual file because it is on my organization's Sharepoint and is restricted. The data above is all that is needed though, I think. Essentially I want the calculation to happen separately for each product, but I want to divide all DEMOS except for Total Panel into DEMOS = Total Panel. So for PROD = DD, Gen Z/Total Panel, Millennial/Total Panel, Gen X/Total Panel, then the same for DD Brand 1. 

 

The result would look like this:

 

davebourgeois87_0-1650306360162.png

 

I really appreciate your help! Let me know if my data table is enough. 

ribisht17
Super User
Super User

Create a FIXED denominator, use ALL here  Solved: Create a fixed denominator - Microsoft Power BI Community

 

Measure 2 = DIVIDE([Count of UserID],CALCULATE([Count of UserID],ALL('warehouse OrderDetails'[Week End])))

 

Regards,

Ritesh

Hi @ribisht17 

 

Thank you for your quick response. I tried taking your suggestion, but it either does not work in this case or I did not apply the concept correctly. It ends up calculating within the demo instead of taking Gen Z % of HH's and dividing by Total Panel % of HH's:

 

davebourgeois87_0-1650302807952.png

 

Do you see anything stand out that I did incorrectly?

 

Thank you.

 

Helpful resources

Announcements
September Power BI Update Carousel

Power BI Monthly Update - September 2025

Check out the September 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.

Top Solution Authors
Top Kudoed Authors