Forum Discussion

Karthik12's avatar
Karthik12
Icon for Post Patron rankPost Patron
3 years ago
Solved

DAX filter support for customized date

Hello Team, Long time I am trying to get the solution for my requirement. I would like to get a table with customized start date and end date. Start date is 27.12.2022 and end date is always today...
  • Anonymous's avatar
    Anonymous
    3 years ago

    Hi Karthik12 ,

    You can create a calculated column as below to get the date range and apply the filter on the visual with the condition(Flag is not blank). Please find the details in the updated sample pbix file.

     

     

    Flag = 
    IF (
        'dates'[Date] >= DATE ( 2022, 12, 27 )
            && 'dates'[Date]
                <= TODAY () - 1,
        'dates'[Date],
        BLANK ()
    )

     

     

    Create a calculated column

    Apply visual level filter with the condition (Flag is not blank)

    Best Regards