Forum Discussion
koorosh
Post Partisan
3 years agoSame Period Last Year
Hi, Why sameperiodlastyear did not result in one year back from the date column selected?
VilmarSch
Post Partisan
3 years agoApparently it's normal:
The SAMEPERIODLASTYEAR is equivalent to DATEADD(dates, -1, year).
Its biggest year in the date table is 2019, so SAMEPERIODLASTYEAR will show the previous year, i.e. 2018.
Its smallest year in the date table is 2014, so SAMEPERIODLASTYEAR will not show the previous year, i.e. 2013.
koorosh
Post Partisan
3 years agoWhy it is normal that does not show 2013? If you use DATEADD(dates, 1, year), and the biggest one is 2016 (attached file) the result shows 2017.