Forum Discussion
Botturovic
8 years agoFrequent Visitor
Problem with "sameperiodlastyear" function
i'm trying to compare sales of two different years by different categories. I've created two measures: Total Amount YTD e Total Amount YTD last year. When i try to insert the second...
v-yulgu-msft
8 years agoMicrosoft Employee
Hi Botturovic,
What is the error message under measure formula and the error message shown in visual?
Did you have a calendar table? I think you should refer to a date field from calendar table in SAMEPERIODLASTYEAR function.
Here are some similar examples for your reference:
SAMEPERIODLASTYEAR – comparison with previous year (DAX – Power Pivot, Power BI)
Get the YTD of same period last year using DAX
Regards,
Yuliana Gu