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,
Please could somebody help with the following?
I use this DAX statement below to Calculate the current period in a column for the current month in my Dates table.
Solved! Go to Solution.
@msommerf - You could add a "Phase" column to your date table. Then in you could do this for your Calculated Column:
Phase Selection=
var phase_today = CALCULATE(max('Dates'[Phase]) ,'Dates'[Date] = TODAY())
return IF([Phase] = phase_today, "Current Phase", "Not Current Phase")Cheers!
Nathan
Sorry if it's something stupid I am doing at this end.
Just learning the rope with DAX.
@msommerf - You could add a "Phase" column to your date table. Then in you could do this for your Calculated Column:
Phase Selection=
var phase_today = CALCULATE(max('Dates'[Phase]) ,'Dates'[Date] = TODAY())
return IF([Phase] = phase_today, "Current Phase", "Not Current Phase")Cheers!
Nathan
@Anonymous
Nathan,
Thanks for such a quick response.
Using your DAX, only today is set as the current phase?
I have a Phase column in my dates table (Phase) which has phases stored as:
2017 Phase 1
2017 Phase 2
2018 Phase 1
2018 Phase 2
2019 Phase 1
2019 Phase 2
If current month is April I need to set the current phase against months of Jan - Jul
If current month is August I need to set the current phase against months of Aug - Dec
regards
Mark.
Sorry if it's something stupid I am doing at this end.
Just learning the rope with DAX.
Hi Nathan,
Spotted my mistake.
I did not change the second column name in the code.
This works perfectly 🙂
Many thanks for your help.
Regards
Mark.
The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!
Check out the November 2025 Power BI update to learn about new features.
| User | Count |
|---|---|
| 59 | |
| 43 | |
| 42 | |
| 23 | |
| 17 |
| User | Count |
|---|---|
| 190 | |
| 122 | |
| 96 | |
| 66 | |
| 47 |