Forum Discussion

Anonymous's avatar
Anonymous
Not applicable
1 year ago
Solved

Table Filter Based on Month Slicer

Hi,

I have Master Customer List Table and Customer Vist Date Table. 

In Table View i Selected customer name and Visit Count. 

While slecting based on month in slicer, am getin all the customer. but i need to view Customer name based on month data only.

Kindly help me.

  • Anonymous's avatar
    Anonymous
    1 year ago

    Hi Anonymous ,

     

    On top of the previous reply, I added a customer dimension table as shown below:

    Create a new relationship:

     

    Modify the meausre:

    Visit Count = CALCULATE(COUNTROWS('Customer Vist Date Table'),MONTH('Customer Vist Date Table'[Visit Date])=SELECTEDVALUE('CalendarTable'[Month]))

     

    Here are the last results:

     

    Best Regards,
    Zhu
    Community Support Team

     

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

     

4 Replies

  • Anonymous , If I understood it correctly. You expect table data(Data View) to be filtered based on the slicer selection.  Or based on filter of other table

     

    That will not happen. Slicer can only filter visual, in your case a visual table

  • Anonymous's avatar
    Anonymous
    Not applicable

    Thanks for the helpful reply from amitchandak.

     

    Hi Anonymous ,

     

    In Power BI Desktop, filtering operations performed in Report View do not directly affect Table View, filters and slicers in Report View are primarily used to visualize the presentation of data, while Table View displays the contents of the original data table.

     

    To achieve the desired effect, you can create a date table:

     

     

    CalendarTable = 
    ADDCOLUMNS (
        CALENDAR (DATE(2024, 1, 1), DATE(2024, 12, 31)),
        "Year", YEAR([Date]),
        "Month", MONTH([Date])
    )

     

     

    Create relationships in Model View:

     

    Using the month field of the date table as a slicer, the result is as follows:

     

    Best Regards,
    Zhu
    Community Support Team

     

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

     

    • Anonymous's avatar
      Anonymous
      Not applicable

      Hi,

      Thanks for Supporting, Vist count is mismatch  

      As per June Month Visit Customer A = 2, and Customer C =0.

      But in your Visit count its shows all customer is 1.

      • Anonymous's avatar
        Anonymous
        Not applicable

        Hi Anonymous ,

         

        On top of the previous reply, I added a customer dimension table as shown below:

        Create a new relationship:

         

        Modify the meausre:

        Visit Count = CALCULATE(COUNTROWS('Customer Vist Date Table'),MONTH('Customer Vist Date Table'[Visit Date])=SELECTEDVALUE('CalendarTable'[Month]))

         

        Here are the last results:

         

        Best Regards,
        Zhu
        Community Support Team

         

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