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

Get Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Request now

Reply
marama
Helper I
Helper I

How to filter for multiple slicer values?

So I have a table with teams (team_id, team_name), and i have a table with projects (project_id, project_name, owner_team_id, developer_team_id). So each project has a team owning the project, and a team developing the project. 
I need to have a teams slicer with multiple selections, and a resulting table showing projects where selected teams are either an owner_team_id or developer_team_id , i.e. all projects relevant to a team shold be listed. Any idea how I can achieve it using DAX?
I've tried FILTER and SELECTEDVALUES, but I didn't get anywhere ;(

The real world case is a bit more compley, with date slicer as well, so projects table is actually already filtered with date slicer, so I need to apply FILTER function on already fileterdd table (with date slicer).

(how can I attach a pbix file to this post?)

1 ACCEPTED SOLUTION
johnt75
Super User
Super User

You could create a measure like

Team belongs to project =
VAR CurrentTeams =
    VALUES ( 'Teams'[Team ID] )
VAR CurrentProjectOwner =
    SELECTEDVALUE ( 'Project'[owner team ID] )
VAR CurrentProjectDev =
    SELECTEDVALUE ( 'Project'[dev team ID] )
RETURN
    IF (
        CurrentProjectOwner
            IN CurrentTeams
            || CurrentProjectDev IN CurrentTeams,
        1
    )

and then use that as a visual level filter on the table to only show when the value is 1

View solution in original post

3 REPLIES 3
v-henryk-mstf
Community Support
Community Support

Hi @marama ,

 

Whether the advice given by @johnt75  has solved your confusion, if the problem has been solved you can mark the reply for the standard answer to help the other members find it more quickly.

 

If not, you can refer to the following link and provide the necessary test information to facilitate me to answer your questions as soon as possible.

How to Get Your Question Answered Quickly - Microsoft Power BI Community


Best Regards,
Henry

johnt75
Super User
Super User

You could create a measure like

Team belongs to project =
VAR CurrentTeams =
    VALUES ( 'Teams'[Team ID] )
VAR CurrentProjectOwner =
    SELECTEDVALUE ( 'Project'[owner team ID] )
VAR CurrentProjectDev =
    SELECTEDVALUE ( 'Project'[dev team ID] )
RETURN
    IF (
        CurrentProjectOwner
            IN CurrentTeams
            || CurrentProjectDev IN CurrentTeams,
        1
    )

and then use that as a visual level filter on the table to only show when the value is 1

Thank you. Weird, I had a similar code, but my code returned true/false, and I wans't able to filter the results. Using 1/blank as you suggest, can be filtered. I wasn't aware of the boolean limitation in filter.

Helpful resources

Announcements
Fabric Data Days Carousel

Fabric Data Days

Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!

October Power BI Update Carousel

Power BI Monthly Update - October 2025

Check out the October 2025 Power BI update to learn about new features.

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.

Top Solution Authors
Top Kudoed Authors
Users online (1,814)