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

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more

Reply
Anno2019
Helper IV
Helper IV

Weight Average using subtotal

Dear Communitiy

 

I am trying to calculate a weighted average using a Sales Persons results only.

In the image below I explain what I am trying to achieve.

The columns in greens should be = [Apples Sales]/[Subtotal Peter Parker], I am not sure how to do this in DAX.

Weighted Average using Subtotal.JPG

1 ACCEPTED SOLUTION
tamerj1
Community Champion
Community Champion

HI @Anno2019 

I will assume that Apple Sales is a measure
Then for the total per sales person = CALCULATE ( [Apple Sales], ALLEXCEPT ( Sales, Sales[Sales Person] ) ) 

ofcourse you need first to decide if the sales person sells to different countries what should be the logic? Would you consider each country seperately or as a whole?

View solution in original post

2 REPLIES 2
tamerj1
Community Champion
Community Champion

HI @Anno2019 

I will assume that Apple Sales is a measure
Then for the total per sales person = CALCULATE ( [Apple Sales], ALLEXCEPT ( Sales, Sales[Sales Person] ) ) 

ofcourse you need first to decide if the sales person sells to different countries what should be the logic? Would you consider each country seperately or as a whole?

@tamerj1 

You rule!  It works!  I will take other countries into consideration later.

Helpful resources

Announcements
Power BI DataViz World Championships

Power BI Dataviz World Championships

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!

December 2025 Power BI Update Carousel

Power BI Monthly Update - December 2025

Check out the December 2025 Power BI Holiday Recap!

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.