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 Community,
How to calculate Half Year to Date and Week to Date from date Field using measure?
Thanks in advance,
Sowmiya
Hi @Sowmiya
Follow Sowmiya's suggestion, you could use YTD, MTD, QTD,WTD,DTD, Half -Year in the measure to calculate the values.
Addition to that, according to your previous post, what you want is partly achieved in Power BI currently.
Per your requirement, the relative date slicer gets us close to this with the “last”, “this”, “next”, of “Day”, “Week”, “Month” or “Year” settings. That is a dynamic date selection that updates based on the current system date.
Please find more details here.
https://docs.microsoft.com/en-us/power-bi/visuals/desktop-slicer-filter-date-range
Currently it doesn't support "Quarter" and "Half year", please vote for this idea to improve this feature
To workaround this, you could create timeperiod slicer, for example
http://analyticsavenue.com/power-bi-timeperiod-slicer-for-last-7-dayslast-30-days/
Best Regards
Maggie
This article might give you some clues of different methods to approach you problem with:
https://www.daxpatterns.com/time-patterns/
For some non-standard period, such as half year, i'd suggest getting this placed into the date table so you can do your half year to date by filtering on these half year markers. For example inside your date table, you could create a field that uses a simple if statement that says "IF month number <= 6 then the HalfYear is the YEARVALUE concatinated with 1, else the HalfYear is the YEARVALUE concatinated with 2"
The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!
| User | Count |
|---|---|
| 40 | |
| 35 | |
| 34 | |
| 31 | |
| 28 |
| User | Count |
|---|---|
| 137 | |
| 102 | |
| 68 | |
| 66 | |
| 64 |