Skip to content

Automatic translation — the Portuguese version is the reference. View in Portuguese

CAMINHO

On this page (10)

Path from the root to the item in the parent-child hierarchy, separated by "|" (e.g., "3|3.1|3.1.2").

FieldValue
CategoryContext and filter
TypeAggregation (operates on a set of rows)
Arity2 arguments (fixed)
Compiles to SQL (calculated column)No
VersionFormula engine v3.

Aliases#

Canonical name: CAMINHO. Accepted aliases (case-insensitive): path.

Syntax#

code
CAMINHO(coluna; arg2)

The 1st argument is the name of a column (bare identifier); the others are expressions.

Returns#

Text (the parent-child path separated by '|').

Null handling#

When there is no row in the changed context, it returns blank (never zero) — a blank is more honest than a made-up zero.

Evaluation context#

Goes through the entire visual to build the parent-child hierarchy (lazy evaluation).

Differences from DAX#

  • DAX equivalent: PATH
  • Compatibility: Compatible with DAX
  • Note: Parent-child path separated by '|', computed over the visual's rows.

Examples#

code
CAMINHO(conta; conta_pai)

Example with values#

Input: account Banco → Caixa → Ativo.

code
CAMINHO(conta; pai)  →  "Ativo|Caixa|Banco"

Expected result: "Ativo|Caixa|Banco"

Business example#

Build the parent→child accounting hierarchy (Ativo|Caixa|Banco) in a chart of accounts.

Common errors#

CAMINHO: coluna desconhecida: … when a column name does not exist.


← Back to the formula index

Related links