Forum Discussion

arane's avatar
arane
Frequent Visitor
1 year ago
Solved

Date picker not filtering tables

The date picker is created on page using
calendar = CALENDAR(Date (2000,1,1), DATE(2040,12,31))
The slicer setting for date picker kept as Between

The 2 queries are added to create grid report and joined date from calendar table with these 2 queries
in order to filter date. the relation is active and one to many.

 

Issues:

The filter is working for one report and not for another.
Also the value getting shown in calendar on first go should be passed to reports which is not happening.

 

Also, want to know how ro debug the table on the page created using power Bi Desktop.

 

  • Anonymous's avatar
    Anonymous
    1 year ago

    Hi arane ,

    You can combine the date columns from all the tables into one column and then use this column to filter those tables.
     
    In my test, there are two tables and they both have a date column.
    The date column is not quite the same for the time portion of each row.

     

    Select the date column of a table, and then select Append Query as New.

     



    Append the two tables into a new table and then delete the columns other than the date column. And de-duplicate the date column.
    This allows you to filter the original table by the date column in that new table.

     



    Please see the attached pbix for reference.

    Best Regards,
    Dengliang Li

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

8 Replies

  • arane 

     

    If everything is as you describe then it should work so there must be something else.

     

    But I'd need your PBIX file to see what that is - can you provide it?

     

    Regards

     

    Phil

  • arane's avatar
    arane
    Frequent Visitor

    Hi Philip

    Thanks for the reply.

    I am not sure even the filter is working or not.

    for range of Year 2000-2038 it showed 2 records

    kindly refer below screenshot

     

    when erased filter and it set up with default values i.e. for year 2000-2040 it showed multiple records for 2024

    soon i will build a report based on sample excel to share so that you can check at your end.

     

    Regards,

    Ashwini

     

     

    • PhilipTreacy's avatar
      PhilipTreacy
      Icon for Super User rankSuper User

      Hi arane 

       

      You said 'for range of Year 2000-2038 it showed 2 records' - is that not what you expect?

       

      You said 'it showed multiple records for 2024' again is this not hat you expect?  If there are multiple records for 2024 then they shoudl al be shown if you include 2024 in your filter.

       

      Please provide data and explain why you think the results as you've shown so far are wrong, and what you expect as a result.

       

      regards

       

      Phil

      • arane's avatar
        arane
        Frequent Visitor

        Hi Philip

         

        I meant if there is data for year 2024 then that should be picked up when date picker has 2000-2038 set.

        I have created this sample data and its not working here as well

         

        CountryDate
        England

        7/12/2024 19:00

        France7/12/2023 19:00
        Italy7/12/2022 19:00
        England7/12/2021 19:00
        France7/12/2020 19:00
        Italy7/12/2019 19:00
          

         

        Can you check at your end?

        Regards,

        Ashwini