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

Creating DAX measure from excel worksheet

 
I have 3 tables:

*Fruit-Ordered*

*Fruit-Sold*

*Fruit+Ordered*

SteelChampzz_0-1665433384737.png

 

 

I've brought this data in from Excel but I need to be able to create a measure in Power BI to create "Percentage" for the Total & also the "percentage" for the Products as well.

 

"Percentage Total"

SteelChampzz_3-1665433445642.png

 


 

 

"Percentage OF TOTAL"

SteelChampzz_6-1665434195790.png

 


 

I've already have a measure for the total of "Sold+Ordered" but having the issues with using "VAR" or "FILTERS" to create the measures for "PERCENTAGE OF THE TOTAL"

 

Any HELP would be awesome, I didn't explain this correctly the first time so hopefully I can get some answer.

Thank everyone

 

 

 

1 ACCEPTED SOLUTION
Shaurya
Memorable Member
Memorable Member

Hi @SteelChampzz,

 

You can use the following DAX formulas:

 

% = 'Table'[Amount]/SUM('Table'[Amount])

 

Index = RANKX('Table','Table'[Product],,ASC)

 

Total = SUMX('Table', IF('Table'[Index]<=EARLIER('Table'[Index]),'Table'[%],0))

 

Result:

 

Screenshot 2022-10-11 042025.jpg

 

Works for you? Mark this post as a solution if it does!

View solution in original post

2 REPLIES 2
Shaurya
Memorable Member
Memorable Member

Hi @SteelChampzz,

 

You can use the following DAX formulas:

 

% = 'Table'[Amount]/SUM('Table'[Amount])

 

Index = RANKX('Table','Table'[Product],,ASC)

 

Total = SUMX('Table', IF('Table'[Index]<=EARLIER('Table'[Index]),'Table'[%],0))

 

Result:

 

Screenshot 2022-10-11 042025.jpg

 

Works for you? Mark this post as a solution if it does!

This defintely helped! Thank you, now my next question is this:

I have 2 tables that I've created these "new columns" in.

Table 1=Order

Table 2=Sold

I want to put "order+Sold" together to create the "Cumulative Total Percentage" for each Product.

How would I write that measure?

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.