Forum Discussion

harry6810's avatar
harry6810
Frequent Visitor
3 years ago
Solved

Lastdate -1 filter

Hi there,  how to calculate measures with LASTDATE -1, -2, -3 etc (or maxstring) filter?   My basic code seems to be working: =CALCULATE(Min('CEN'[Price]);LASTDATE(CEN[Data]))   I've tried like...
  • johnt75's avatar
    3 years ago
    Day before =
    VAR MaxDate =
        MAX ( Ceneo[Date] )
    RETURN
        CALCULATE ( MIN ( Ceneo[Price] ), Ceneo[Date] = MaxDate - 1 )