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

We've captured the moments from FabCon & SQLCon that everyone is talking about, and we are bringing them to the community, live and on-demand. Starts on April 14th. Register now

Reply
Anonymous
Not applicable

Data Modeling Question-Using one slicer to filter multiple categories (sample dashboard included)

Hi,

 

I have a table of names and their corresponding categories. Some names have multiple categories and some only have one. They are separated by a comma:

 

PowerBI2020_0-1607695055258.png

 

I am trying to have one slicer that filters by category so that when "Football" is selected, Jim and Ned come up. I want the slicer to only have "Football", "Basketball", "Baseball", etc. as options and not "Football,Basketball,Baseball".

 

I've split the Category column up by the comma delimeter and also created a category dimension table (see below).  

PowerBI2020_1-1607695229566.png

 

PowerBI2020_2-1607695260285.png

 

Now I'm not sure what to do as this is what my model looks like, and the slicer only filters the Category.1 column.

PowerBI2020_3-1607695307288.png

 

As you can see, in my current dashboard when "Football" is selected, only Jim comes up, not Ned because "Football" is his Category.3.

PowerBI2020_4-1607695640876.png

 

Sample Dashboard: https://www.dropbox.com/s/wcz65qs5iyahwk1/Multiple%20Category%20-%20One%20Slicer.pbix?dl=0

 

Thank you in advance!

1 ACCEPTED SOLUTION
v-yingjl
Community Support
Community Support

Hi @Anonymous ,

Create the Category table like this by spliting columns and removing replicated values, do not create relationships between this table and the source table.

category.png

Create a measure like this, put it in the table visual filter and set its value as 1:

Visual control = 
IF (
    CONTAINSSTRINGEXACT (
        SELECTEDVALUE ( 'Table'[Category] ),
        SELECTEDVALUE ( Category[Category] )
    ),
    1,
    0
)

filter.png

Attached a sample file in the below, hopes to help you.

 

Best Regards,
Community Support Team _ Yingjie Li
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

2 REPLIES 2
v-yingjl
Community Support
Community Support

Hi @Anonymous ,

Create the Category table like this by spliting columns and removing replicated values, do not create relationships between this table and the source table.

category.png

Create a measure like this, put it in the table visual filter and set its value as 1:

Visual control = 
IF (
    CONTAINSSTRINGEXACT (
        SELECTEDVALUE ( 'Table'[Category] ),
        SELECTEDVALUE ( Category[Category] )
    ),
    1,
    0
)

filter.png

Attached a sample file in the below, hopes to help you.

 

Best Regards,
Community Support Team _ Yingjie Li
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

HotChilli
Community Champion
Community Champion

Unpivot the Non-Person columns and you'll get one column with all the sports in.

Relate this to the category slicer.

 

Good luck

Helpful resources

Announcements
New to Fabric survey Carousel

New to Fabric Survey

If you have recently started exploring Fabric, we'd love to hear how it's going. Your feedback can help with product improvements.

Power BI DataViz World Championships carousel

Power BI DataViz World Championships - June 2026

A new Power BI DataViz World Championship is coming this June! Don't miss out on submitting your entry.

Join our Fabric User Panel

Join our Fabric User Panel

Share feedback directly with Fabric product managers, participate in targeted research studies and influence the Fabric roadmap.

March Power BI Update Carousel

Power BI Community Update - March 2026

Check out the March 2026 Power BI update to learn about new features.