Forum Discussion
PATH function error
- 5 years ago
FYI that you likely need to address the distinct parent issue, but you can use the Bonus Function at the end of this article to perform the equivalent of the PATH function in your query (and it doesn't have the single parent limitation).
Guest Post: Using List.Accumulate for Input/Output Genealogy – The BIccountant
Pat
Hi selimovd
I use the hierarchy column created by the path function for the RLS. I use the PATHCONTAINS function to search the hierarchy column for the userprincipalname. I use this on many of my datasets, so I know it works well.
I guess I don't understand why my calculate function doesn't work to filter out the multiple managers. The second half of the function "Filter('Staff by Quarter','Staff by Quarter'[Quarter] = EARLIER('Staff by Quarter'[Quarter])" should filter the table down to just one Quarter and therefore eliminate the fact that there are different Manager IDs for different quarters. That's the part I'm attempting to figure out how to tweak to make this thing work.
Hey jhartranft60 ,
you get the error in the first half of the measure:
CALCULATE(PATH('Staff by Quarter'[Employee ID],'Staff by Quarter'[Manager ID])
Here the employee 4567 has manager 8888 and manager 7777. This ambiguity is not allowed, so there will be an error.