Forum Discussion

wemsomba10's avatar
wemsomba10
Frequent Visitor
1 year ago
Solved

FILTERING THREE SLICERS

Hello. I have two identical tables. one is the selected and the other the compared. i want to compare them based on time period.

 

selecte table    compared table

Amount           Amount

12                    12

14                    14

15                    15

 

now i have these measures

Total Selected amount = sum of selected table amount

total Compared amount = sum of compared table amount

amount difference = total selected amount - total compared amount.

 

now i have these filters

. total selected amount

total compared amount

Amount difference

I want to be able to do this. if i select total selected amount filter, it should selected the select total compared amount in the compared filter and amoutn difference in the difference filter. If i had another level let's say "revenue". if revenue is selected in selected revenue, then compared revenue and revenue difference should be selected. 

 

please help. here is an example in the picture below. 

 

 

 

  • Anonymous's avatar
    Anonymous
    1 year ago

    Hi wemsomba10 ,

    Thank you for reaching out to the Microsoft Fabric Community.

     

    Currently, Power BI does not natively support automatic synchronization between slicers, which explains the behavior you're encountering.

    To achieve the functionality you're looking for, we recommend implementing a single unified slicer using a custom table for example, a "MeasureSelector" that includes all the base measures like "WO $", "Assignment Received", and others. With this setup, you can use DAX and the SWITCH() function to dynamically calculate and return the selected, compared, and difference values based on the user's slicer selection.

    This approach simplifies the report experience and eliminates the need for manual slicer syncing, while still supporting your comparison requirements.

     

    Hope this solution meets your needs. If you have any further questions or need additional support, please feel free to ask.

    If this post helped resolve your issue, please consider marking it as the accepted solution so that others can benefit as well. A kudos would also be appreciated!

     

    Thank you.

2 Replies

  • Anonymous's avatar
    Anonymous
    Not applicable

    Hi wemsomba10 ,

    Thank you for reaching out to the Microsoft Fabric Community.

     

    Currently, Power BI does not natively support automatic synchronization between slicers, which explains the behavior you're encountering.

    To achieve the functionality you're looking for, we recommend implementing a single unified slicer using a custom table for example, a "MeasureSelector" that includes all the base measures like "WO $", "Assignment Received", and others. With this setup, you can use DAX and the SWITCH() function to dynamically calculate and return the selected, compared, and difference values based on the user's slicer selection.

    This approach simplifies the report experience and eliminates the need for manual slicer syncing, while still supporting your comparison requirements.

     

    Hope this solution meets your needs. If you have any further questions or need additional support, please feel free to ask.

    If this post helped resolve your issue, please consider marking it as the accepted solution so that others can benefit as well. A kudos would also be appreciated!

     

    Thank you.

  • Hi wemsomba10 ,

     

    If you're working with three slicers (Period1, Period2, Period3) and want to dynamically compare selected vs. compared tables, you’ll probably need to create measures that respond to slicer context.

    Here’s a rough idea to get you started:

    1. Total Selected Amount
    Total Selected Amount = SUM('SelectedTable'[Amount])
    1. Total Compared Amount
    Total Compared Amount = SUM('ComparedTable'[Amount])
    1. Absolute Difference
    Absolute Difference = [Total Selected Amount] - [Total Compared Amount]
    1. Reverse Difference
    Reverse Difference = [Total Compared Amount] - [Total Selected Amount]
    1. Variance Flag
    Variance Flag = IF([Absolute Difference] > 0, "Y", "N")

    To make this work per period, you’ll need to make sure your model has a Period dimension and both tables are related to it. Then your slicers should come from that Period table, not directly from the fact tables.

    Let me know if you want help setting up the relationships or writing the measures per period!

    If my response resolved your query, kindly mark it as the Accepted Solution to assist others. Additionally, I would be grateful for a 'Kudos' if you found my response helpful.