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

Find everything you need to get certified on Fabric—skills challenges, live sessions, exam prep, role guidance, and more. Get started

Not applicable

building a hierarchy in the matrix table

I am trying to create a matrix table where I could show my organizational chart through a hierarchy based on who is reporting to whom based on the designation. For Example : Resource -> Supervisor -> Manager -> Director -> Sr Director -> Vice President -> SR Vice President OR Resource -> Manger -> Director -> SR Vice President. The issue is that I need to create a hierarchy based on the organizational hierarchy the psoition is designated but since the data is segregated into different levels based on the first level of data, the dataset looks like below





And I need a table showing an hierarchy something like this



Ideally I would have segregated the dataset based on the different designation to create a better hierarchy but since different people have different designation in the same row I am unable to create a hierarchy. 


I created a query to sort out the resoures to a unique column based on the levels in a particular row are empty or not.


ResourceName_v2 = IF(OrgHierarchy_v2[ResourceName_2]="", (IF(OrgHierarchy_v2[ResourceName_1]="",(IF(OrgHierarchy_v2[Supervisor]="",(IF(OrgHierarchy_v2[Manager]="",(IF(OrgHierarchy_v2[Director]="",(IF(OrgHierarchy_v2[SR Director]="","Empty",OrgHierarchy_v2[SR Director])),OrgHierarchy_v2[Director])),OrgHierarchy_v2[Manager])),OrgHierarchy_v2[Supervisor])),OrgHierarchy_v2[ResourceName_1])),OrgHierarchy_v2[ResourceName_2]) 



Is there a way or a visual where I can get the correct hierarchy to display the relavent information? Any help would be appreciated.


Sample data is uploaded to the following onedrive location!AkUUe-6V4o1Ug2RxVsHLIVzU8vtV















Follow the below steps,




Let me know if anything is required.

View solution in original post

Not applicable

hi @v-xjiin-msft,

I need your help, as when i am trying to create hierarchy using matrix visual.

Facing below issues:


1) Blanks are appearing, if trying to apply visual filter complete level from its root gets vanished.

Please provide a way to avoid blank in hiearrachy as it happens in hierarchy slicer.


2) there are 4 more slicers apart from matrix slicer as and when i select any other slicer, matrix slicer automatically shows result of its top most is quite annoying, have i need to set an property to stop defaulting to top most member even if it is selected somewhere else.


Your help is needed.Thank you in advance.

Solution Sage
Solution Sage

Hi @Anonymous,


Sorry but I'm not quite understand your requirement. And the column names in your shared sample data don't match the column names in your query. So I don't understand your query either.


Based on your sample data, did you mean the first level of hierarchy is ResourceName as in sheet OrganizationHierarchy, it is the values from right side? 


Could you please share is your desired result based on your sample data? So that we can get a right direction.


Xi Jin.

Resident Rockstar
Resident Rockstar

Hello @Anonymous,


Is that your expected result(based on the sample data)?



Not applicable

@SivaMani Yes, this is the excepted result. Can you share the sample .pbix file or let me know how to achieve the excepted result?



Follow the below steps,




Let me know if anything is required.

Is there any way, to get the titles repeated in each row.

@SivaMani- Kudos to you for including a video tutorial in your answer.

Helpful resources

July 2024 Power BI Update

Power BI Monthly Update - July 2024

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

July Newsletter

Fabric Community Update - July 2024

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

Top Solution Authors