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

Get certified in Microsoft Fabric—for free! For a limited time, get a free DP-600 exam voucher to use by the end of 2024. Register now

Reply
puru85
Helper II
Helper II

Daily Sales Target Calculation

Hi Experts,

I am trying to calculate the Daily Sales Target. 

Logic for Daily Sales Target Calculation:
 (50,000 / number of workdays) + 20%

Details:

  • I have created a measure to calculate the number of workdays. (The Workdays measure is attached in the PBIX file.)
  • I have also created a measure for the Daily Sales Target. The measure is working fine; however, it is affected by the day filter. This issue seems to be due to the workdays measure. (The Daily Sales Target measure is attached in the PBIX file.)


I have attached my PBIX file for reference.
DailySalesTarget.pbix

Any guidance on how to ensure the Daily Sales Target measure is not affected by the day filter would be greatly appreciated.

Thank you for your help!

 








 

1 ACCEPTED SOLUTION

@puru85 

I think the solution of workday was provided by another super user. You have some discustion on another thread. I haven't had a chance to go through. 

 

Here is a workaround that we do not need to touch the DAX part.

 

turn off the interaction between day filter and daily sales target card.

 

11.png12.PNG





Did I answer your question? Mark my post as a solution!

Proud to be a Super User!




View solution in original post

5 REPLIES 5
puru85
Helper II
Helper II

@ryan_mayu ,

The output  of "Daily Sales Target" is correct, if YEAR and MONTH Filter are selected

puru85_0-1721264125145.png

However, If DAY filter selected along with YEAR and MONTH filter. The output "Daily Sales Target" is showing incorrect result. This is due to "Workday" measure filter is affected by Day Filter. 

My requirement is to workday measure should not be affected by Day Filter. 

puru85_1-1721264240640.png

 



 

@puru85 

I think the solution of workday was provided by another super user. You have some discustion on another thread. I haven't had a chance to go through. 

 

Here is a workaround that we do not need to touch the DAX part.

 

turn off the interaction between day filter and daily sales target card.

 

11.png12.PNG





Did I answer your question? Mark my post as a solution!

Proud to be a Super User!




puru85
Helper II
Helper II

@Ritaf1983 @ryan_mayu 

If possible please help me with solution. 


Thank you!

the output looks correct. 50000/20*1.2

What's the expected output that you want?





Did I answer your question? Mark my post as a solution!

Proud to be a Super User!




davidding
Resolver I
Resolver I

got a feeling that the problem is with the 50,000, is that a monthly target? my interpretation of your problem is that this total target is not changing, but the number of workday changed, so your daily target is also affected.

 

I've split the measures into 3 tables in your file using different period in the table to illustrate the problem. Hope this at least partially answered your question.  

davidding_0-1721211546467.png

 

Helpful resources

Announcements
November Carousel

Fabric Community Update - November 2024

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

Live Sessions with Fabric DB

Be one of the first to start using Fabric Databases

Starting December 3, join live sessions with database experts and the Fabric product team to learn just how easy it is to get started.

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! Early Bird pricing ends December 9th.

Nov PBI Update Carousel

Power BI Monthly Update - November 2024

Check out the November 2024 Power BI update to learn about new features.