Forum Discussion

Anonymous's avatar
Anonymous
Not applicable
1 year ago
Solved

Switch measure

Hello, Im using following measure to calculate growth: Total Tickets Growth W = ([Total Tickets] - [Total Tickets LW])/[Total Tickets LW] Total Tickets Growth M = ([Total Tickets] - [Total Tick...
  • danextian's avatar
    1 year ago

    Hi Anonymous 

    I am assuming those slicers are from a field parameter (please provide more context).

     

    A field parameter table includes a column named "Parameter Order." Use this column in your SWITCH formula to toggle between calculations based on the field selected from the slicer.

     

    Sample measure

    SWITCH (
        SELECTEDVALUE ( 'field parameter'[parameter order] ),
        1, [Month on Month Growth],
        2, [Week on Week Growth]
    )