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

To celebrate FabCon Vienna, we are offering 50% off select exams. Ends October 3rd. Request your discount now.

Reply
Greg1
Frequent Visitor

Combining many dynamic slicers into one slicer (via Field Parameters or otherwise)

I have a large (c.10GB) data set in a fact table within Power BI. Each row in the fact table has about 20 categorical fields (eg showing the Product, Year, Smoker, Region etc) and each category has between 2 to 20 possible values (eg for Smoker:"Y" or "N", or for Year: 2018, 2019, 2020, 2021, 2022, 2023).

 

Current Approach:

Currently I use bookmarks in Power BI with predefined combinations of slicer selections. However, due to the large number of slicers, selections and the need for an audit-trail, I want to implement a Master Slicer where users can select a single "Filter Name" that automatically applies multiple slicer conditions based on predefined filter settings stored in a CSV file.

 

Desired Functionality

The Master Slicer should allow users to select a single filter option, which will automatically apply all the corresponding slicer selections.

The filter definitions will be stored in an external "Slicer Selections" CSV file (simplified example with just 4 categories below), specifying the slicer values for each Filter ID. 

 

It should also support:

  • Wildcard selections (e.g., "All" instead of listing every possible value).
  • Overlapping selections (e.g., the "East" region may appear in multiple filters).
  • I would like the slicers to be applied to everything in the report, or at least at the visualisation-level. I don't want to have to put every single existing measure into a DAX formula that does the filtering for every individual category.
  • Multiple selections within a single cell (e.g., Year: "2020, 2021, 2022" instead of separate rows for each year). However, I understand I could deal with this somehow when importing via PowerQuery.
  • Ideally allow for new categories to be added in the future without significant developments   

Any help would be greatly appreciated (or letting me know if this just simply isn't possible!) 

 

Let me know if you need any more information on this in order to help. Thanks!

 

Simpilfied Example CSV of slicer selections:

 

Filter IDFilter NameProductYearSmokerRegion
1XPC_Y_NEXPCAllYNorth, East
2H87_RecentH872020, 2021, 2022AllAll
3AllAllAllAllAll
4All: 2020+All2020, 2021, 2022, 2023, 2024AllAll
5All_N_EastAllAllNEast
6All_N_NorthAllAllNNorth

 

1 ACCEPTED SOLUTION
Deku
Super User
Super User

Calculation groups.

 

Each filter combo would be a separate calculation item.

 

I.e.

XPC_Y_NE =

Calculate(

Selected measure(),

Datum[products] = "XPC",

Datum[smoker] = "y",

Treatas( {"North","East"}, datum[Region])

)

 

If you add this in a slicer then all measures in visuals will be calculated within that filter context. You might want to wrap each filter in keepfilters if you want to intersect with user filter selections for those fields


Did I answer your question?
Please help by clicking the thumbs up button and mark my post as a solution!

View solution in original post

6 REPLIES 6
V-yubandi-msft
Community Support
Community Support

Hi @Greg1 ,

May I ask if you have resolved this issue? If so, please mark the helpful reply and accept it as the solution. This will be helpful for other community members who have similar problems to solve it faster.

Thank you.

V-yubandi-msft
Community Support
Community Support

Hi @Greg1 ,

We haven’t received a response yet and want to ensure the solution met your needs. If you need any further assistance, feel free to reach out we’d be happy to help. If everything is working as expected, kindly mark it as Accepted as solution.

 

Thank You.

V-yubandi-msft
Community Support
Community Support

Hi @Greg1 ,

I wanted to check if you had the opportunity to review the information provided @Deku . If it did, please consider marking the answer 'Accept as Solution' so others with similar queries may find it more easily. If not, please share the details.

Thank you.

Greg1
Frequent Visitor

Thanks very much, but is there a way do to this without having to manually create separate calculation items for each filter combination? 

I was really hoping for each filter combination to be driven directly off of a separate Master Table of filter combinations, so that all filters are shown in one central place for easy checking & updating, and so Power BI would automatically update if the Master Table was updated. 

 

I have tried using Field Parameters along with a filter mapping table for combinations of filters, which nearly worked, but failed to filter text columns correctly when there are multiple entries of the same text in the filter table (eg. having multiple filters with "East" in the "Region" column). This seems to be a limitation of the Field Parameters approach.

 

Is there a way of making the Field Parameters+Mapping table flexible enough to support my points above, or a different, fairly automated way?

Thanks!

You might struggle with the "All" parts. You could inject the values into the TREATAS. For the All would be fine if you had a list that represented all items but would be hard to maintain. You can't easily say if All then don't filter as IF is a bit funny about returning tables


Did I answer your question?
Please help by clicking the thumbs up button and mark my post as a solution!
Deku
Super User
Super User

Calculation groups.

 

Each filter combo would be a separate calculation item.

 

I.e.

XPC_Y_NE =

Calculate(

Selected measure(),

Datum[products] = "XPC",

Datum[smoker] = "y",

Treatas( {"North","East"}, datum[Region])

)

 

If you add this in a slicer then all measures in visuals will be calculated within that filter context. You might want to wrap each filter in keepfilters if you want to intersect with user filter selections for those fields


Did I answer your question?
Please help by clicking the thumbs up button and mark my post as a solution!

Helpful resources

Announcements
August Power BI Update Carousel

Power BI Monthly Update - August 2025

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

August 2025 community update carousel

Fabric Community Update - August 2025

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

Top Kudoed Authors