cancel
Showing results for
Did you mean:

Find everything you need to get certified on Fabric—skills challenges, live sessions, exam prep, role guidance, and more. Get started

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.

1 ACCEPTED SOLUTION
Super User

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?

2 REPLIES 2
Super User

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?

Helper IV

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

Announcements

#### Europe’s largest Microsoft Fabric Community Conference

Join the community in Stockholm for expert Microsoft Fabric learning including a very exciting keynote from Arun Ulag, Corporate Vice President, Azure Data.