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

Next up in the FabCon + SQLCon recap series: The roadmap for Microsoft SQL and Maximizing Developer experiences in Fabric. All sessions are available on-demand after the live show. Register now

Reply
Lannie84
New Member

How to stop my pie chart from hiding columns in my matrix when a pie slice is selected

I have a large 50k+ row data set for a survey that is run annually. I have some of the data displayed in a matrix similar to this:

 

LocationYearVariable 1Variable 2Variable 3Variable 4Variable 5
One2020aabaccdaea
Two2020aabbccdbed
Three2020aabdccdbea
Four2020abbdccdcee
Five2020abbccaddec
Six2020acbbcddaee
Seven2020abbdcbdbed
Eight2020acbacbddea
Nine2020aabacadcea
Ten2020acbcccdded

 

I currenty have working slicers to include/exclude different survey years and various location parameters (such as state, country etc.). I want to add a some sort of pie chart or slicer that allows users to filter the matrix by specific variable responses.

 

For example: One user is only interested in the responses to variables 2-5 when variable 1 is "aa".

When I add a pie chart for Variable 1 and select "aa", all the other variable columns (2-5) are removed from my matrix and I get a matrix like this:

 

LocationYearVariable 1
One2020aa
Two2020aa
Three2020aa
Nine2020aa

 

Instead I want the matrix to look like this:

LocationYearVariable 1Variable 2Variable 3Variable 4Variable 5
One2020aabaccdaea
Two2020aabbccdbed
Three2020aabdccdbea
Nine2020aabacadcea

 

The current data I have in the visuals are like this.

Matrix visual:                                                                          Pie chart visual:

Lannie84_0-1674599829801.png   Lannie84_1-1674599959809.png

 

Here is my dummy data:

https://drive.google.com/file/d/1iSj35n-rpWLWL4Raq0KZsbOxqKz14I-n/view?usp=sharing

1 ACCEPTED SOLUTION
olgad
Resident Rockstar
Resident Rockstar

Hi, there,
Filtering happens based on rows and the columns created in the visual matrix are actually rows in your data. 
Here is the result, you have to duplicate your table in Power Query, select variable column and pivot it. 
Then create a primary key between two tables using concatinate 

Key = Sheet1[Year]&"-"&Sheet1[Location]&"-"&Sheet1[City]&"-"&Sheet1[State]&"-"&Sheet1[Country] 
Make the Cross filtering : Both. 
Change the visual from Matrix to Table. 

olgad_0-1674603732077.png

Dummy data.pbix


DID I ANSWER YOUR QUESTION? PLEASE MARK MY POST AS A SOLUTION! APPRECIATE YOUR KUDO/LIKE!
PROUD TO BE A SUPER USER!
Best Stories, Interesting Cases: PowerBI Storytime Newsletter
Linkedin Profile: Linkedin
YouTube Channel: PowerBI Storytime

View solution in original post

1 REPLY 1
olgad
Resident Rockstar
Resident Rockstar

Hi, there,
Filtering happens based on rows and the columns created in the visual matrix are actually rows in your data. 
Here is the result, you have to duplicate your table in Power Query, select variable column and pivot it. 
Then create a primary key between two tables using concatinate 

Key = Sheet1[Year]&"-"&Sheet1[Location]&"-"&Sheet1[City]&"-"&Sheet1[State]&"-"&Sheet1[Country] 
Make the Cross filtering : Both. 
Change the visual from Matrix to Table. 

olgad_0-1674603732077.png

Dummy data.pbix


DID I ANSWER YOUR QUESTION? PLEASE MARK MY POST AS A SOLUTION! APPRECIATE YOUR KUDO/LIKE!
PROUD TO BE A SUPER USER!
Best Stories, Interesting Cases: PowerBI Storytime Newsletter
Linkedin Profile: Linkedin
YouTube Channel: PowerBI Storytime

Helpful resources

Announcements
New to Fabric survey Carousel

New to Fabric Survey

If you have recently started exploring Fabric, we'd love to hear how it's going. Your feedback can help with product improvements.

Power BI DataViz World Championships carousel

Power BI DataViz World Championships - June 2026

A new Power BI DataViz World Championship is coming this June! Don't miss out on submitting your entry.

Join our Fabric User Panel

Join our Fabric User Panel

Share feedback directly with Fabric product managers, participate in targeted research studies and influence the Fabric roadmap.

March Power BI Update Carousel

Power BI Community Update - March 2026

Check out the March 2026 Power BI update to learn about new features.