Join us at FabCon Atlanta from March 16 - 20, 2026, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.
Register now!The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more
Hi,
How can I calculate the difference of sales for example between working days? i have the problem on monday that dax look back at sunday when i need to calculate the difference with friday, not sunday.
Thanks a lot.
Solved! Go to Solution.
If I understand correctly you're trying the find the difference between a value on a certain day and the value from the day prior. However, if the day selected is a Monday, you want to find the difference between Monday and the previous Friday.
In this image the red lines are what your formula is doing, but you want it to find the previous the Friday instead.
I believe this can be done with Lookups:
An if statement can determine if the selected day is a Monday and will Lookup the value from three days ago instead of one day ago. In this example I have excluded the calculation from being run on weekends as, from your prompt, it seems those days are being ignored.
I hope this is helpful!
Thanks 🙂
If I understand correctly you're trying the find the difference between a value on a certain day and the value from the day prior. However, if the day selected is a Monday, you want to find the difference between Monday and the previous Friday.
In this image the red lines are what your formula is doing, but you want it to find the previous the Friday instead.
I believe this can be done with Lookups:
An if statement can determine if the selected day is a Monday and will Lookup the value from three days ago instead of one day ago. In this example I have excluded the calculation from being run on weekends as, from your prompt, it seems those days are being ignored.
I hope this is helpful!
Thanks 🙂
The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!
| User | Count |
|---|---|
| 37 | |
| 37 | |
| 33 | |
| 32 | |
| 29 |
| User | Count |
|---|---|
| 130 | |
| 88 | |
| 82 | |
| 68 | |
| 64 |