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 experts, need to calculate total sales for the current year and last year based on the fiscal year (apr - mar). I have year filter in the report. I need to calculate based on the selected year. Please help.
Solved! Go to Solution.
Hi @Anonymous ,
Try to create measures like below:
Sales FYTD =
TOTALYTD( [Total Sales],
Dates[Date], ALL( Dates[Date] ), "30-6"
)Sales PY FYTD =
CALCULATE( [Sales FYTD],
SAMEPERIODLASTYEAR( Dates[Date] )
)
Best Regards,
Liang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
@Anonymous , Using date table and time intelligence
YTD Sales = CALCULATE(SUM(Sales[Sales Amount]),DATESYTD('Date'[Date],"3/31"))
Last YTD Sales = CALCULATE(SUM(Sales[Sales Amount]),DATESYTD(dateadd('Date'[Date],-1,Year),"3/31"))
Power BI — Year on Year with or Without Time Intelligence
https://medium.com/@amitchandak.1978/power-bi-ytd-questions-time-intelligence-1-5-e3174b39f38a
https://www.youtube.com/watch?v=km41KfM_0uA
Time Intelligence, DATESMTD, DATESQTD, DATESYTD, Week On Week, Week Till Date, Custom Period on Period,
Custom Period till date: https://youtu.be/aU2aKbnHuWs
@amitchandak In my report, year filter only available. Abobe formula will work for date range filter, right?
Hi @Anonymous ,
Try to create measures like below:
Sales FYTD =
TOTALYTD( [Total Sales],
Dates[Date], ALL( Dates[Date] ), "30-6"
)Sales PY FYTD =
CALCULATE( [Sales FYTD],
SAMEPERIODLASTYEAR( Dates[Date] )
)
Best Regards,
Liang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!
| User | Count |
|---|---|
| 38 | |
| 36 | |
| 33 | |
| 30 | |
| 28 |
| User | Count |
|---|---|
| 128 | |
| 88 | |
| 79 | |
| 67 | |
| 62 |