Forum Discussion

Datatouille's avatar
Datatouille
Icon for Solution Sage rankSolution Sage
10 years ago
Solved

DAX issue with interim measure and time intelligence

Hello everyone,   I have a problem with a DAX measure. Let me explain : I have a Sales table (including a column named "Sales") and a classic Calendar table (including a column named "Year") in m...
  • v-micsh-msft's avatar
    10 years ago

    Hi Excelside,

     

    We could just create another year column, add 1 to the existing year, then use this new column as the slicer. This should work.

     Yearslicer = Calendar[Year]  + 1 

    In addition, if you have a calendar table, then we could switch the lastyearsales formula with the following one:

    [Sum Of Sales LY] = Calculate ( [Sum of Sales], DATEADD(DATESYTD('Calendar'[Date]),-1,Year))

    See the result from my side:

    If any further assistance needed, please feel free to post back.

    Regards