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

The ultimate Microsoft Fabric, Power BI, Azure AI & SQL learning event! Join us in Las Vegas from March 26-28, 2024. Use code MSCUST for a $100 discount. Register Now

Reply
DarylRob
Helper I
Helper I

Slicer that only shows user names in the other table

Hi, 

 

So I have two tables, one is my primary table RESULTS that is solely used for the report and this has "OwnerID" in it and then I have a USER table which i'm pulling the users name based on the OwnerID

When I create a slicer on Name from the USER table it gives me all names, not just those that are in the RESULTS table, how can I just show those names with an OwnerID in the RESULTS table..

 

Cheers, 

1 ACCEPTED SOLUTION
v-shex-msft
Community Support
Community Support

Hi @DarylRob,

Currently, you can’t directly do this on your slicer. I'd like to suggest writing a measure formula and use on a slicer to achieve filter records.

formula =
VAR userList =
    ALLSELECTED ( Table2[UserName] )
RETURN
    IF ( SELECTEDVALUE ( Table1[UserName] ) IN userList, "Y", "N" )

Regards,

Xiaoxin Sheng

Community Support Team _ Xiaoxin
If this post helps, please consider accept as solution to help other members find it more quickly.

View solution in original post

4 REPLIES 4
v-shex-msft
Community Support
Community Support

Hi @DarylRob,

Currently, you can’t directly do this on your slicer. I'd like to suggest writing a measure formula and use on a slicer to achieve filter records.

formula =
VAR userList =
    ALLSELECTED ( Table2[UserName] )
RETURN
    IF ( SELECTEDVALUE ( Table1[UserName] ) IN userList, "Y", "N" )

Regards,

Xiaoxin Sheng

Community Support Team _ Xiaoxin
If this post helps, please consider accept as solution to help other members find it more quickly.
VIJAYKUMART
Resolver I
Resolver I

hi.. provide some sample data and exact column names u have and  it is more clear expected output is mentioned

truptis
Community Champion
Community Champion

@DarylRob -> Did it work? 

truptis
Community Champion
Community Champion

Hi @DarylRob ,
You can put a filter on your visual which says OwnerID from USERS table is "Not Blank"
Steps: 
1- Select your visual and drag and drop the OwnerID field in the filters pane.
2- Select Advanced filtering and select is not blank option
3- Click on Apply

@DarylRob  Please accept it as a solution if this helps you. Thank you.
Regards,
TruptiS

Helpful resources

Announcements
Fabric Community Conference

Microsoft Fabric Community Conference

Join us at our first-ever Microsoft Fabric Community Conference, March 26-28, 2024 in Las Vegas with 100+ sessions by community experts and Microsoft engineering.

February 2024 Update Carousel

Power BI Monthly Update - February 2024

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

Fabric Career Hub

Microsoft Fabric Career Hub

Explore career paths and learn resources in Fabric.

Fabric Partner Community

Microsoft Fabric Partner Community

Engage with the Fabric engineering team, hear of product updates, business opportunities, and resources in the Fabric Partner Community.