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!Get Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Request now
Hi All
I have a issue , when i my Date expression :-
CALENDAR(Date(2003,01,01),date(2021,12,31))
Today is Jan 18 2022 ,My YTD expression below it will return Last year Total sales amount.
Solved! Go to Solution.
Hi Paul,
Couple of things: Have you gone through the process of marking your Date table as a calendar table? (Right click the table name from your Fields pane > Mark as date table > Mark as date Table > select your unique date column)
If so, then you can simplify your expression to just be:
CALCULATE (
[SALES],
DATESYTD('DATES'[Date])
)
Then you can add a year slicer to your canvas. Whichever year you select will give you the YTD value for that value for that year.
Cheers
Hi Paul,
Couple of things: Have you gone through the process of marking your Date table as a calendar table? (Right click the table name from your Fields pane > Mark as date table > Mark as date Table > select your unique date column)
If so, then you can simplify your expression to just be:
CALCULATE (
[SALES],
DATESYTD('DATES'[Date])
)
Then you can add a year slicer to your canvas. Whichever year you select will give you the YTD value for that value for that year.
Cheers
This is the best reply i get in 2022. Thank you very much. it is what i am looking for.
Paul
Check out the November 2025 Power BI update to learn about new features.
Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!
| User | Count |
|---|---|
| 104 | |
| 81 | |
| 66 | |
| 50 | |
| 45 |