Forum Discussion

Anonymous's avatar
Anonymous
Not applicable
3 years ago
Solved

Filtering Out Values Per Year

Hello,     I'm having issue where my filer is filtering out values for all years and not per year. For example, if I have a list of 10 people with traffic violations between 2010 to 2020. How do I ...
  • v-yadongf-msft's avatar
    3 years ago

    Hi Anonymous ,

     

    This is my test table:

     

    Create a measure:

    Count of violation = 
    CALCULATE (
        COUNT ( 'Table'[Name] ),
        FILTER (
            ALLEXCEPT ( 'Table', 'Table'[Year] ),
            'Table'[Name] = SELECTEDVALUE ( 'Table'[Name] )
                && 'Table'[Violation] = "Yes"
        )
    )

     

    Create a slicer from [Year] column and create a table visual:

     

    Put the measure into the filter pane:

     

    You can show people with more than 2 traffic violations PER YEAR and not all years.

    Best regards,

    Yadong Fang

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