PATHITEM DAX function in Power BI

The PATHITEM DAX function returns the item at the specified position from a string resulting from evaluation of a PATH function. Positions are counted from left to right.

Syntax PATHITEM(path, position[, type])

The function has the following parameters:

Return value: The identifier returned by the PATH function at the specified position in the list of identifiers. Items returned by the PATH function are ordered by most distant to current.

Example: The following example returns the third-tier manager of the current employee.

DAX

PATHITEM Column = 
    PATHITEM(
        Employees[HierarchyPath], 
        3, 
        INTEGER
    )        

The output of the above code is shown below:

PATHITEM DAX Function Output