Forum Discussion
Anonymous
4 years agoNot applicable
Help comparing two different periods using SAMEPERIOD()
Hi all! I've been stuck on this problem for a few weeks now, tried a few solutions I found online but couldn't solve the issue at hand. I've been trying to compare the value of some KPIs between i...
Ashish_Mathur
Super User
4 years agoHi,
The Year and Quarter columns should be in the Calendar Table. To your visual/slicer/filters, drag any date dimenion such as year, month, quarter from the Calendar Table. Revised your measures to:
1) Total Atributes = sum('database'[Valor])
2) Total Atributes LY = calculate(Total Atributes, sameperiodlastyear(Calendar[Date]))
3) % Diference = divide([total atributes] - [total atributes LY],[total atributes LY])
Hope this helps.