Forum Discussion

Anonymous's avatar
Anonymous
Not applicable
4 years ago
Solved

Date Filtering - +2 months from current date without including all months in between

Hi There,    I have 3 pages where each of the pages should show only the specific values for "this month", "next month", "+2 month". Example for this month: Page 1: Shows only values for May 20...
  • v-cazheng-msft's avatar
    4 years ago

    Hi Anonymous,

     

    You may try this solution.

    1 Create a Measure

    DateIn+2Month =
    VAR CurrentMon =
        MONTH ( TODAY () )
    VAR ExpectedMon = CurrentMon + 2
    RETURN
        CALCULATE (
            COUNT ( 'Table'[MS110(B)] ),
            FILTER ( 'Table', MONTH ( 'Table'[MS110(B)] ) = ExpectedMon )
        )

     

    2 Use this Measure as a visual filter, then only data for July will be displayed in the visual

     

    Also, attach the sample pbix as reference.

     

    If this post helps, then please consider Accept it as the solution to help the other members find it more quickly. If I misunderstand your needs or you still have problems on it, please feel free to let me know. Thanks a lot!

     

    Best Regards,

    Community Support Team _ Caiyun