Forum Discussion

MrNoob's avatar
MrNoob
Icon for Helper II rankHelper II
6 years ago
Solved

all months except current mont

Need a measure to calculate all months except the current month

  • Hi MrNoob ,

     

    We can try to use the following measure to meet your requirement:

     

    Result =
    CALCULATE (
        [YourCalculateFormula],
        FILTER (
            ALL ('Table') ,
            YEAR ( [Date] ) <> YEAR ( TODAY () )
                || MONTH ( [Date] ) <> MONTH ( TODAY () )
        )
    )

    Best regards,

    Community Support Team _ Dong Li
    If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

4 Replies

  • Anonymous's avatar
    Anonymous
    Not applicable

    Hi, can you please share a sample data what you are working on?

     

    I think we can use ALLEXCEPT and MONTH(TODAY()) combination in the measure to help with this one.

  • v-lid-msft's avatar
    v-lid-msft
    Icon for Community Support rankCommunity Support

    Hi MrNoob ,

     

    We can try to use the following measure to meet your requirement:

     

    Result =
    CALCULATE (
        [YourCalculateFormula],
        FILTER (
            ALL ('Table') ,
            YEAR ( [Date] ) <> YEAR ( TODAY () )
                || MONTH ( [Date] ) <> MONTH ( TODAY () )
        )
    )

    Best regards,

    Community Support Team _ Dong Li
    If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

    • MrNoob's avatar
      MrNoob
      Icon for Helper II rankHelper II

      This worked perfectly.  Thank you 🙂

  • v-lid-msft's avatar
    v-lid-msft
    Icon for Community Support rankCommunity Support

    Hi MrNoob ,


    How about the result after you follow the suggestions mentioned in my original post?Could you please provide more details about it If it doesn't meet your requirement?

     

    Best regards,

    Community Support Team _ Dong Li
    If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.