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

Enhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.

Reply
ge97aa
New Member

having trouble with simple slicer logic

I'm a Power BI beginner. I think this should be super simple, but for whatever reason I can't get my head around it. Let's say I have the following table called MyTable:

 

RecordNameRecordType

A

special
Bnormal
Cnormal
Dspecial
Enormal

 

Now, I want a single-selection slicer with two values:

  • "Show all records"
  • "Show special records only"

This slicer should filter records in the manner indicated by the slicer value. i.e.:

  • "Show all records" will select all records
  • "Show special records only" will select ONLY records A and D (i.e. the "special" records)

That's it. I want the slicer to have ONLY those two options - either I get ALL the records or ONLY the special records. It should not allow selection of ONLY the "normal" records. How can I do this?

1 ACCEPTED SOLUTION
Anonymous
Not applicable

@ge97aa  A more simple approach is to create the slicer table this way. It's hard to tell if it'd be scalable without knowing more about your MyTable data source.

 

bchager6_2-1679864693687.png

 

Then connect the tables on RecordType

 

bchager6_1-1679864663152.png

 

It produces the same results:

bchager6_3-1679864769382.png

bchager6_4-1679864792151.png

 

 

 

View solution in original post

5 REPLIES 5
Anonymous
Not applicable

@ge97aa  This might not be a scalable solution but it works. Others might suggest solutions in DAX or M.

  1. Create a slicer table using the Enter Data function within the Home tab of the Power Query Editor with "Show all records" rows for every RecordName and "Show Special Records Only" rows for special RecordNames
    bchager6_0-1679710277417.png
  2. Connect the slicer table to MyTable on RecordName with the Cross filter direction set to both.
    bchager6_1-1679710356174.png
  3. Bring the SlicerValue column from the SlicerTable in to a slicer
    bchager6_2-1679710492482.pngbchager6_3-1679710521328.png

     

 

Thanks! This works for my current purposes, but I agree that it lacks scalability. I'll wait a bit for a potentially more general scalable solution before accepting yours as "the" solution.

 

Nonetheless, greatly appreciated.

Anonymous
Not applicable

@ge97aa  A more simple approach is to create the slicer table this way. It's hard to tell if it'd be scalable without knowing more about your MyTable data source.

 

bchager6_2-1679864693687.png

 

Then connect the tables on RecordType

 

bchager6_1-1679864663152.png

 

It produces the same results:

bchager6_3-1679864769382.png

bchager6_4-1679864792151.png

 

 

 

Yes, I actually settled on that solution before you mentioned it 😉. It does, of course, require a many-to-many relationship, but I suspect that should not cause any unintended side effects as long as I ONLY use this new table for this specific filtering purpose.

Ritaf1983
Super User
Super User

Hello @ge97aa.
This can be achieved with some "cosmetic" tricks.

1. Put the record type on the slicer.
Enable the options:
"show selecet all..."
and
"multi select..."
Here is a picture

Ritaf1983_0-1679707536627.png

2. Sort your record types descendingly.
As shown in the picture

Ritaf1983_1-1679707687988.png

3. Hide "normal" by zooming out the slicer

Ritaf1983_2-1679707886547.png

4. Lock the form with:
"Lock aspect ratio"

Ritaf1983_3-1679708102313.png

5.Insert a white shape without a border to hide the vertical scroll

Ritaf1983_4-1679708373173.png

6. With formatting options, bring this shape to the front

Ritaf1983_5-1679708528739.png

7. Group the shape with the slicer

Ritaf1983_6-1679708673695.png

sample file here:
https://drive.google.com/file/d/1AhJuilPBnKO36-EFzD6bnFCX5BEIMSAD/view?usp=sharing 

If my answer was helpful please give me a Kudos and accept as a Solution.

Regards,
Rita Fainshtein | Microsoft MVP
https://www.linkedin.com/in/rita-fainshtein/
Blog : https://www.madeiradata.com/profile/ritaf/profile

Helpful resources

Announcements
July 2025 community update carousel

Fabric Community Update - July 2025

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

July PBI25 Carousel

Power BI Monthly Update - July 2025

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

Join our Fabric User Panel

Join our Fabric User Panel

This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.