By Dany Hoter
(Download file here to follow along).
Time intelligence functions are some of the most important functions in DAX.
Being able to compare values between current period and the same period last year is a very common request and one that is a real challenge using native Excel and can easily achieved with DAX.
A typical calculated field might look like:
Sales Last Year:=CALCULATE(
In quite a few cases once you start using such expressions you will see this annoying error message:
The reason is that the time intelligence functions like the one used here SAMEPERIODLASTYEAR require 100% completely consecutive dates in the filter context, with no holes.