Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
silkwire
Frequent Visitor

Filter table by different column than slicer selection value

I have a scenario where I want to list a table of stores filtered by one level higher hierarchy than the store selected.

 

So normal, slicer interaction, the user selects the store from slicer and the table is filtered to that store:

silkwire_0-1670593227738.png

 

but I want the table to display all stores in the selected store's area, not just the single store. Like this:

 

silkwire_1-1670593265702.png

How do I accomplish this? 

1 ACCEPTED SOLUTION
johnt75
Super User
Super User

You could create a disconnected copy of the stores and areas for use in the slicer, e.g.

Table for slicer = SUMMARIZE( 'Table', 'Table'[Store], 'Table'[Area])

Use the store column from this new table on the slicer, then create a measure like

Store is visible =
IF (
    SELECTEDVALUE ( 'Table'[Store] )
        IN CALCULATETABLE (
            VALUES ( 'Table'[Store] ),
            TREATAS ( VALUES ( 'Table for slicer'[Area] ), 'Table'[Area] )
        ),
    1
)

and add that as a visual level filter to your table, set to show only when the value is 1.

View solution in original post

2 REPLIES 2
silkwire
Frequent Visitor

That worked perfectly! Thanks

johnt75
Super User
Super User

You could create a disconnected copy of the stores and areas for use in the slicer, e.g.

Table for slicer = SUMMARIZE( 'Table', 'Table'[Store], 'Table'[Area])

Use the store column from this new table on the slicer, then create a measure like

Store is visible =
IF (
    SELECTEDVALUE ( 'Table'[Store] )
        IN CALCULATETABLE (
            VALUES ( 'Table'[Store] ),
            TREATAS ( VALUES ( 'Table for slicer'[Area] ), 'Table'[Area] )
        ),
    1
)

and add that as a visual level filter to your table, set to show only when the value is 1.

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

Find out what's new and trending in the Fabric Community.