Forum Discussion

MagnusSthlm's avatar
MagnusSthlm
Helper I
8 years ago
Solved

Rolling quarter

Hi!   I'm trying to create a chart with rolling quarter. I'm stuck. Today is Q1 but I want to present the graph as let's say you are in December it should display 4 bars Q4, Q1, Q2, Q3 in that orde...
  • v-chuncz-msft's avatar
    8 years ago

    MagnusSthlm,

     

    Drag [Date] to Axis, expand to the Quarter level and add measure below. It takes advantage of Show Categories With No Data.

    Measure =
    VAR d =
        MIN ( 'Calendar'[Date] )
    VAR n =
        DATEDIFF ( d, TODAY (), QUARTER )
    RETURN
        IF ( n >= 1 && n <= 4, 1 )