Forum Discussion
Anonymous
7 years agoNot applicable
SamePeriodLastYear error
Hi All,
I am doing a headcount report and would like to use the SamePeriodLastYear function to calculate last year headcount, however, the results are wrong and the numbers look strange. Any ideas?
6 Replies
- Zubair_MuhammadCommunity Champion
Anonymous
In the Table Visual, are you using the Month column from Calendar table?
- AnonymousNot applicable
i am using the "Month" in Calender table as the row content.
- v-piga-msftResident Rockstar
Hi Anonymous,
What about use the formula below?
py = CALCULATE ( SUM ( 'Table1'[Headcount] ), FILTER ( 'Table', YEAR ( 'Table'[Date] ) = YEAR ( MAX ( 'Table'[Date] ) ) - 1 ) )Here is the output.
If you still want to use Time Intelligence functions for your case, please share some data sample and the relationship between the tables.
Best Regards,
Cherry