DAX Function Guide
PATHITEM
Sam McKay
CEO & Founder
How does the PATHITEM work?
PATHITEM Formula Syntax
PATHITEM(
<path>, <position>[, <type>]
)
How do you use the PATHITEM?
This function can be used to return a specific level from a hierarchy returned by a PATH function. For example, you could return just the skip-level managers for all employees.
Related Blog Posts
Loading
Considerations when using the PATHITEM?
- If you specify a number for position that is less than one (1) or greater than the number of elements in path, the PATHITEM function returns BLANK
- If type is not a valid enumeration element an error is returned.
- This DAX function is not supported for use in DirectQuery mode.
Related Video Tutorials
Loading
Formula examples using the PATHITEM
=PATHITEM(PATH(Employee[EmployeeKey], Employee[ParentEmployeeKey]), 3, 1)
= PATHITEM(PATH(Employee[EmployeeID], Employee[ManagerEmployeeID]), Employee[P ath Length]-2)
=PATHITEM([PCPath],1,1)
Related Courses
Loading