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 - I am putting together a volume variance calculation that normalizes for working days. I've built an IsWorking Day column into my date table to return a value of 1 for working days that I can count for whatever time period I'm analyzing.
Solved! Go to Solution.
Hi @a119526 ,
Not very clear about what you mean 'DAX doesn't seem to want to cooperate with dates in IF statements'.
Can't you use formula like below?
IF(month('table'[date])=month(today()),expression1,expression2)
If I misunderstood your meaning, please share some sample data and the formulas you are using.
Best Regards,
Jay
Hi @a119526 ,
Not very clear about what you mean 'DAX doesn't seem to want to cooperate with dates in IF statements'.
Can't you use formula like below?
IF(month('table'[date])=month(today()),expression1,expression2)
If I misunderstood your meaning, please share some sample data and the formulas you are using.
Best Regards,
Jay
@a119526 , datesmtd can help
calculate(sum('Date'[IsWorkingDay]), datesmtd('Date'[Date]))
or
MTD=
var _max = maxx(allselected(Table), Table[Date])//table having data till 20th
var _min = eomonth(_max,-1) +1
return
CALCULATE(sum('Date'[IsWorkingDay]), FILTER(ALL('Date'),'order'[Date] >= _min && 'Date'[Date] <=_max ) )
The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!
| User | Count |
|---|---|
| 56 | |
| 45 | |
| 35 | |
| 34 | |
| 21 |
| User | Count |
|---|---|
| 143 | |
| 122 | |
| 100 | |
| 80 | |
| 57 |