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
Hello All,
I'm new user and new to the PBi community.
I have a problem in getting Previous Year (2021) cumlated sales showing full againest that of YTD 2022 CumSales for my report.
Anyone can help with right DAX formular? Thanks!
Here is the report:
Here is the Formular:
@JMSHI007 , Try a measure like
Last YTD Sales = CALCULATE(SUM(Sales[Sales Amount]),DATESYTD(dateadd('Date'[Date],-1,Year),"12/31"))
Cumm Sales = CALCULATE(SUM(Sales[Sales Amount]),filter(allselected(date),date[date] <=max(date[Date])))
Cumm year behind
Cumm Sales =
var _max1 = max(date[Date])
var _max = date(year(_max1)-1, month(_max1), day(_max1))
return
CALCULATE(SUM(Sales[Sales Amount]),filter(allselected(date),date[date] <=_max))
Thanks you for your fast reply.
I've applied your solution, it works with pending issue still.
It gives me all 4 years YTDcumulated instead of Y2021.
We already fix year-reset per year before.
Thank you so much.
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 | |
| 46 | |
| 42 | |
| 23 | |
| 18 |
| User | Count |
|---|---|
| 190 | |
| 122 | |
| 96 | |
| 66 | |
| 47 |