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

Compete to become Power BI Data Viz World Champion! First round ends August 18th. Get started.

Reply
zb134
Helper I
Helper I

How to calculate layers from a dependent set of data?

Sorry about the title but it's hard to condense it to a sentence and make sense.

 

This is what I am trying to achieve (col C):

NameReports ToLayers From D
AB3
BF2
CF2
D-0
EB3
FD1

 

Given Col A and Col B, I want a calculated column to see how far a person is in the reporting structure from D. So for example, C reports to F who reports to D, so 2 layers from D.

 

From a programming perspective, I think the approach is to go iteratively go through each person in COl A and use a counter to add +1 until person D is reached. But I am lost on how to implement it in PBI. Any suggestions?

1 ACCEPTED SOLUTION
Boofus
Regular Visitor

 using path function 

View solution in original post

1 REPLY 1
Boofus
Regular Visitor

 using path function 

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 Solution Authors