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

Don't miss out! 2025 Microsoft Fabric Community Conference, March 31 - April 2, Las Vegas, Nevada. Use code MSCUST for a $150 discount. Prices go up February 11th. Register now.

Reply
Anonymous
Not applicable

Sales Calculation to ignore filters

Hi Experts

 

I am trying to work out a sales rate calculation that ignores filters. so here is the scenario.

I have 4 filters (Region, Country, Site and Department) the columns used for the filters come from 4 tables.

I am using the following DAX

Sales Y2 = CALCULATE([Sales],
ALL(PMS_PARTS[DEPARTMENT]),ALL(PMS_COMPLAINT[MANUFACTURING_REGISTERED_SITE]),All(PMS_COUNTRY[MDR_REPORTING_REGION]),
PMS_TM1_SALES_VOLUME[Fiscal Period] = "Y"
)
This formula works fine, it ignore the filter for Region, Site and Department, and gives me the correct sales for country UK £4m. 
This issue is when only UK is selected as a filter i would except my Sales Rate calculation to be = Divide(the number of issues/sales for UK). However, the above formula is giving me the sales assoicated with the individual issues / the sales for the issues (as opposed to the total UK Sales)
 
I want to be able to divide the issue by total sales..... 

 

 

 

1 ACCEPTED SOLUTION
Anonymous
Not applicable

Hi Amit

 

I worked the solution based on your help

Sales Y = CALCULATE([Sales],
ALL(PMS_COMPLAINT[REPORTED_FAILURE_MD_CD]),ALL(PMS_PARTS[PMS_FILE]),ALL(PMS_COMPLAINT[MANUFACTURING_REGISTERED_SITE]),All(PMS_COUNTRY[MDR_REPORTING_REGION]),
PMS_TM1_SALES_VOLUME[Fiscal Period] = "Y"
)

View solution in original post

3 REPLIES 3
amitchandak
Super User
Super User

@Anonymous ,

I did not get it completely . Need better examples and data.

 Sales Y2 = if( firstnonbank(table[Country],blank())="UK",Divide([Issue]/[sales]),CALCULATE([Sales],
ALL(PMS_PARTS[DEPARTMENT]),ALL(PMS_COMPLAINT[MANUFACTURING_REGISTERED_SITE]),All(PMS_COUNTRY[MDR_REPORTING_REGION]),
PMS_TM1_SALES_VOLUME[Fiscal Period] = "Y")
)

 

Full Power BI Video 20 Hours YouTube
Microsoft Fabric Series 60+ Videos YouTube
Microsoft Fabric Hindi End to End YouTube
Anonymous
Not applicable

Hi Amit

 

I worked the solution based on your help

Sales Y = CALCULATE([Sales],
ALL(PMS_COMPLAINT[REPORTED_FAILURE_MD_CD]),ALL(PMS_PARTS[PMS_FILE]),ALL(PMS_COMPLAINT[MANUFACTURING_REGISTERED_SITE]),All(PMS_COUNTRY[MDR_REPORTING_REGION]),
PMS_TM1_SALES_VOLUME[Fiscal Period] = "Y"
)

@Anonymous , Thanks for sharing.  Kudos!!

Full Power BI Video 20 Hours YouTube
Microsoft Fabric Series 60+ Videos YouTube
Microsoft Fabric Hindi End to End YouTube

Helpful resources

Announcements
Las Vegas 2025

Join us at the Microsoft Fabric Community Conference

March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount! Prices go up Feb. 11th.

Jan25PBI_Carousel

Power BI Monthly Update - January 2025

Check out the January 2025 Power BI update to learn about new features in Reporting, Modeling, and Data Connectivity.

Jan NL Carousel

Fabric Community Update - January 2025

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