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
Anonymous
Not applicable

How to Hide rows in Matrix Chart using Parent Child Hierarchy

Hi Experts, I have read and tried many different ways to implement below, but just can't get it right. I may very well be missing something obvious

 

Desired Result: in Matrix Chart, for rows, only show selected level together the levels under this selected level, but not showing rows above this selected level. 

 

What has tried:

 1. build a table: Entity Name List using Dax from table: Entity; Table Entity Name List has no relationship with Table Entity.

          Using EntityKey as slicer for selecting specific Entity, which will show in Matrix Chart. 

 2. build a measure: Total forSelectedEntity

 3. Creat Matrix Chart as below, the measure is showing fine for the selected entity, but the rows starting from level1. 

lillianliyi_0-1647885895450.png

 

The expected Chart should be as below:

lillianliyi_1-1647885986332.png

 Appreciated any help/suggestions. 

 

6 REPLIES 6
Anonymous
Not applicable

@Anonymous , thank you so much for helping. 

I do have a sample file in my local laptop folder, but not able to attach. I have replied the email from Power BI Community Administrator <mailer@us.khoros-mail.com> and attached the file. if this email address does not work for you, is there any other email which I can use ?

Please let me know if you have any question on this sample file.

 

I did use an unconnected table as the source of the slicer (Table: Entity Name List). 

As shown in mine post, the challenge is to how to hide the level1 and level2' s name in the row header ( the measure for level1 and level2 are blank, this is fine).

 

Again, Appreciated your help. 

lillianliyi

Anonymous
Not applicable
Anonymous
Not applicable

HI @Anonymous,

I test on your sample file and find I can't directly hide the parent level when you work with hierarchy fields. (these levels are interactive and the child level will also be removed if you hide the parent level)
Perhaps you can try to change your field structure like the following blog then you can use a filter to hide the corresponding level records.

Dynamic Attributes In A Power BI Report - P3 Adaptive

Regards,

Xiaoxin Sheng

Anonymous
Not applicable

HI @Anonymous,

You can upload a sample file to the network driver and share the link here or try to export these data to an excel sheet and paste the dummy table records here in table format.

Regards,

Xiaoxin Sheng

Anonymous
Not applicable

HI @Anonymous,

It sounds like you want to achieve custom filter effects on the matrix based on slicer selections, right? In my opinion, I think the default filter effect is not suitable for your reuqrement.

For this scenario, you can try to create an unconnected table as the source of the slicer then write a measure express to achieve your requirement and apply it to the matrix visual level filter.

Applying a measure filter in Power BI - SQLBI

If you are confused about the coding formula, can you please share a pbix or some dummy data that keep raw data structure with expected results? It should help us clarify your scenario and test to coding formula.

How to Get Your Question Answered Quickly  

Regards,

Xiaoxin Sheng

Anonymous
Not applicable

Hi Xiaoxin Sheng, 

Applying a measure filter is not applicable for solving the issue I am running into. 

 

Here is the link for the sample file: 

https://www.dropbox.com/s/6fgpekabzuf8rlt/How%20to%20Hide%20Levels%20in%20Matrix_byParentChildHierar...

Highly appreciated the help. 

 

Yi

Helpful resources

Announcements
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.

June 2025 community update carousel

Fabric Community Update - June 2025

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