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
JM_nxgn
Helper I
Helper I

Limiting Filter Options

Hi I'm busy building reports which have numerous filters on many different columns. 

Is there a way to limit the number of filter options based on a previous choice of filter.

I'll provide an example, consider the table below:

 

AnimalBreed
DogGerman Shepherd
DogChow
CatSiamese
CatRussian Blue
DogChow
CatSiamese
DogCorgi

 

So say I have two columns, one with the animal type and the other with the specific breed. If I have filters on both columns. How do i change the filters such that if I filter Animal to 'Dog' then the available options when I want to filter by Breed is limited to only 'German Shepherd, Chow, Corgi'?

 

Thanks

EDIT: I forgot to mention I'm using report level filtering. I have to use report level filtering for this, not sure if it makes a difference. I'm not using slicers at all, only the filters on the right bar.

1 ACCEPTED SOLUTION
Mariusz
Community Champion
Community Champion

Hi @JM_nxgn 

 

Please see the below solution.

1. Create a measure 

_filter = INT( NOT ISEMPTY( Owner ) )

2. Use this measure as a filter on both sliners like below.

image.png

Second option is to create one dimension table that contains both Breed and Animal and link it to Owner on Breed ID, and this would be the best practice.

 

Best Regards,
Mariusz

If this post helps, then please consider Accepting it as the solution.

Please feel free to connect with me.
Mariusz Repczynski

 

View solution in original post

6 REPLIES 6
Anonymous
Not applicable

adding to that what will be the max number of report filters we can use in dashboard?

Mariusz
Community Champion
Community Champion

Hi @JM_nxgn 

 

Not sure if I understand what you need, but if you have one table with both columns in than the behaviour should be as below.

 

image.png

Please let me know if that is what you expecting.

 

Best Regards,
Mariusz

If this post helps, then please consider Accepting it as the solution.

Please feel free to connect with me.
Mariusz Repczynski

 

@Mariusz 

 

Okay I think I've found the issue, just not too sure on what procedure to follow in order to fix this. Probably something to do with creation of dimension tables (which I'm not too familiar with).

 

So the table I mentioned in the first post was created by these three tables: 

 

AnimalIdAnimal
1Dog
2Cat

 

BreedIdBreed
aChow
bCorgi
cGerman Shepherd
dSiamese
eRussian Blue

 

OwnerIdAnimalIdBreedId
11c
21a
32d
42e
51a
62d
71b

 

But then I'm using the respective AnimalName and BreedName as the filters and not their respective Id's. 

Would this be a cause as to why it's not limiting the filter options? How would i fix this?

 

Thank you!

Mariusz
Community Champion
Community Champion

Hi @JM_nxgn 

 

Please see the below solution.

1. Create a measure 

_filter = INT( NOT ISEMPTY( Owner ) )

2. Use this measure as a filter on both sliners like below.

image.png

Second option is to create one dimension table that contains both Breed and Animal and link it to Owner on Breed ID, and this would be the best practice.

 

Best Regards,
Mariusz

If this post helps, then please consider Accepting it as the solution.

Please feel free to connect with me.
Mariusz Repczynski

 

@Mariusz 

 

Hi I just noticed now what you said is true. I made a table with the two columns and does exactly as what you mentioned. 

I don't know why this isn't the case with the table I have created though. I'm using report level filters on the right side bar if that makes any difference?

Mariusz
Community Champion
Community Champion

Hi @JM_nxgn 

 

If you filter visual in the Filters Pane then you are filtering only the visuals display, it does not propagate to the model for some reason, however if you apply your filter on this page / all pages levels, then you will get the desired result as below.

 

image.png

 

Best Regards,
Mariusz

If this post helps, then please consider Accepting it as the solution.

Please feel free to connect with me.
Mariusz Repczynski



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.