PATHITEMREVERSE DAX Function (Parent-child)

Zwraca n-ty element z rozdzielanej listy utworzonej przez funkcję Path, licząc w tył od ostatniego elementu w ścieżce.

Syntax

PATHITEMREVERSE ( <Ścieżka>, <Pozycja> [, <Typ>] )
Parameter Attributes Description
Ścieżka

Ciąg zawierający rozdzielaną listę identyfikatorów.

Pozycja

Liczba całkowita wskazująca pozycję od prawego końca ścieżki.

Typ Optional

Argument opcjonalny. Jeśli zostanie pominięty lub będzie mieć wartość 0, ta funkcja zwróci ciąg. Jeśli będzie mieć wartość 1, ta funkcja zwróci liczbę całkowitą.

Return values

Scalar A single value of one these types: integer, string.

The n-position ascendant in the given path, counting from current to the oldest.

Remarks

  • This function can be used to get an individual item from a hierarchy resulting from a PATH function.
  • This function reverses the standard order of the hierarchy, so that closest items are listed first, For example, if the PATh function returns a list of managers above an employee in a hierarchy, the PATHITEMREVERSE function returns the employee’s immediate manager in position 2 because position 1 contains the employee’s id.
  • If the number specified for position 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.

Related functions

Other related functions are:

Last update: Dec 14, 2019   » Contribute   » Show contributors

Contributors: Alberto Ferrari, Marco Russo

MSDN documentation: https://docs.microsoft.com/en-us/dax/pathitemreverse-function-dax

DAX Conventions
Context Transition

This function performs a Context Transition if called in a Row Context. Click to read more.

Row Context

This expression is executed in a Row Context. Click to read more.

Iterator

Not recommended

The use of this function is not recommended. See Remarks and Related functions for alternatives.

Not recommended

The use of this parameter is not recommended.

Deprecated

This function is deprecated. Jump to the Alternatives section to see the function to use.

Deprecated

This parameter is deprecated and its use is not recommended.

Contribute

Want to improve the content of PATHITEMREVERSE? Did you find any issue?
Please, report it us! All submissions will be evaluated for possible updates of the content.


This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.