Forum Discussion

Anonymous's avatar
Anonymous
Not applicable
6 years ago
Solved

Filter a table visual using a date slicer

Hellp, Power friends,   I have a table (visual) with two date colluns (begin a end date vacation) and a slicer with the vacation date interval. I need to filter the visual to show only the vacation...
  • v-frfei-msft's avatar
    6 years ago

    Hi Anonymous ,

     

    I've created a sample for your reference. Please note here we shouldn't create relationship between date table and the fact table.

     

    Measure = 
    VAR mind =
        MIN ( 'date'[Date] )
    VAR maxd =
        MAX ( 'date'[Date] )
    VAR sdate =
        MAX ( 'Table'[S-date] )
    VAR edate =
        MAX ( 'Table'[E-date] )
    RETURN
        IF ( sdate <= mind && edate >= maxd, "in", BLANK () )