Skip to content

hierarchy.rootElements

Returns all the root elements for a hierarchy in a dimension.

js
hierarchy.rootElements(dimension, hierarchy)
hierarchy.rootElements(dimension, hierarchy)

Parameters

  • dimension - The dimension in which the hierarchy exists in which to check for a root elements.
  • hierarchy - The hierarchy in which root members need to be listed.

Example

js
let members = JSON.parse(hierarchy.rootElements("Account", "Profit and Loss"));
let members = JSON.parse(hierarchy.rootElements("Account", "Profit and Loss"));