Hi,
There must be fairly simple way to achieve this however I am looking for a way to calculate this logic in DAX for a requirement which basically needs adding of Weekend (Sat or Sun) values of QTY over to Monday…
I have a date column coming from date_dim and qty fact coming from On Prem SQL server(Direct Query)
Sample & Desired Data attached data.xlsx (11.4 KB)
That’s great!
You can upgrade this solution by including holidays.
Let’s say, holiday is on Monday than the volume is moved to Tuesday (if that’s your case of course).
You can find below my measure.
It’s long but simple (I had to figure out the correct total).
Thanks for your extended solution and accurate guidance on my initial requirement.
I would need some direction on Additional logic on retrieving previous value.
Requirement is to exclude Weekends and bring Friday Value over to Monday as Prev Value so I used the below DAX which is working fine as expected.
How can I exclude Holiday’s as well ? I have IsHoliday Flag True/False coming from my Dates time dimension table so whenever there is a holiday it is giving blank prev value whereas I need to retrieve the previous working day value
Let me try to explain how holidays may be included
The key part is the following variable, which returns the last working day earlier than actual date…