Forum Discussion

RichFlorida's avatar
RichFlorida
Helper V
4 years ago
Solved

Dynamic Date filter on a Chart

  Hello All,   I need to add a filter to my chart to make it display data for current_year only. I want this filter to be dynamic, this year will be 2022, but next year will automatically change ...
  • Anonymous's avatar
    Anonymous
    4 years ago

    Hi  RichFlorida ,

    I created some data:

    2019 1.1 – 2023.12.31

    Here are the steps you can follow:

    1. Create measure.

    Flag =
    IF(
        YEAR(MAX('Table'[Date]))=YEAR(TODAY()),1,0)

    2. Place [Flag]in Filters, set is=1, apply filter.

    3. Result:

    Only data for the current year will be displayed

     

    Best Regards,

    Liu Yang

    If this post helps, then please consider Accept it as the solution to help the other members find it more quickly