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

Power BI is turning 10! Let’s celebrate together with dataviz contests, interactive sessions, and giveaways. Register now.

Reply
jodyclaggett
Frequent Visitor

DAX % of Grand Total from Variable

I need help calculating the % of grand total based on a variable calculation in an asymetical matrix. 

Here is my table values that I need to calculate on:

jodyclaggett_4-1621890428442.png

Essentially, I need to divide 834655.70/69945935.43 striped across the entire table to get what percentage of the over 90 that is in the total grouping. The problem I'm having is that I'm using variables to create these columns, in an asymetrical matrix and there doesn't seem to be a way to strip the grand total (69945935.43) across the entire grouping to then use that value in a DIVIDE funcation. SUM and SUMX both look for a table, but I'm using a variable. Do I need to create a table from my variable and if so, how do I do that?

 

Here's my code to calculate the columns:

jodyclaggett_3-1621890357223.png

 

EatbTotal is the variable that contains the grand total (denominator) and Over90 is the numerator. 

 

Any ideas how I can do this?

 

1 ACCEPTED SOLUTION
jodyclaggett
Frequent Visitor

So, I actually figured this out. I had to create a seperate measure entirely that striped the total by group across the column and then use that measure in my variable calculation. 

 

jodyclaggett_0-1622039590246.png

 

And then in the Values to Display measure:

 

jodyclaggett_1-1622039682019.png

 

 

 

 

View solution in original post

3 REPLIES 3
jodyclaggett
Frequent Visitor

So, I actually figured this out. I had to create a seperate measure entirely that striped the total by group across the column and then use that measure in my variable calculation. 

 

jodyclaggett_0-1622039590246.png

 

And then in the Values to Display measure:

 

jodyclaggett_1-1622039682019.png

 

 

 

 

Greg_Deckler
Super User
Super User

@jodyclaggett Could you just do this?

DisplayItem = 12, Over90 / EatbTotal,



Follow on LinkedIn
@ me in replies or I'll lose your thread!!!
Instead of a Kudo, please vote for this idea
Become an expert!: Enterprise DNA
External Tools: MSHGQM
YouTube Channel!: Microsoft Hates Greg
Latest book!:
Power BI Cookbook Third Edition (Color)

DAX is easy, CALCULATE makes DAX hard...

That gives me % over 90 for the row, but not the grand total for the Total column.  That is effectively Total/Over 90 Days whereas I need the Grand Total of Total/Over 90 days. 

Helpful resources

Announcements
Join our Fabric User Panel

Join our Fabric User Panel

This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.

June 2025 Power BI Update Carousel

Power BI Monthly Update - June 2025

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

June 2025 community update carousel

Fabric Community Update - June 2025

Find out what's new and trending in the Fabric community.

Top Solution Authors