Forum Discussion

LuckyeLies's avatar
LuckyeLies
Regular Visitor
5 years ago
Solved

Choose specific dates based on filters

Hello guys,    Need your help on doing something that I can't understand how to do it, already tried 1001 things but nothing works.   Well, I need to do something relatively easy on theory... I n...
  • v-jingzhang's avatar
    5 years ago

    Hi LuckyeLies 

     

    If I understand it correctly, you want to select a date in a slicer or a filter, then in a table it will show data in the previous 365 days of the selected date dynamically, right?

     

    If so, you need to have an independent date table in the model to contain all dates to be selected in the filter. This table is not connected to any other table in the model. Then create a flag measure to determine whether a date in the fact table (or another date table which is connected to fact table in the model) are in the previous 365 days of the selected date. Put date column from fact table into a table visual and put flag measure into the visual as a filter. 

     

    Here is a sample for your reference. It shows the previous 10 days of a selected date.

     

    Regards,
    Community Support Team _ Jing
    If this post helps, please Accept it as the solution to help other members find it.