External hierarchies represent master data and are used in reporting for alternative views of data. External hierarchies may be loaded from source systems by using predefined SAP BW/4HANA content data flows or the BW Hierarchy Framework. Alternatively, they may be created directly in SAP BW/4HANA.
External hierarchies comprise a series of nodes that are joined to one another in a tree structure. Usually, the leaves of a hierarchy are represented by characteristic values.
These hierarchies are called external because their data is not part of the InfoProvider on which your query is based, but is master data belonging to the characteristic, independent of whether it is loaded to or created in SAP BW/4HANA.
Creating External Hierarchies
Create external hierarchies for basic characteristics, for example, Product (0D_NW_PRID). A basic characteristic does not refer to other characteristics.
Determine whether a characteristic can have a hierarchy in the InfoObject maintenance.
Define the properties of hierarchies, for example, hierarchy versions or time-dependent hierarchy structures.
The external hierarchies are saved in special master data tables. External hierarchies behave like master data; you can use them in all InfoProviders that contain the hierarchy characteristic.
Define several external hierarchies for a characteristic.
Note
In most cases, external hierarchies are not created directly in SAP BW/4HANA, but rather loaded from source systems.
Adding External Hierarchies to a Report
In SAP HANA Studio, select the characteristic that you want to display as a hierarchy.
Go to the Properties section on the right side of SAP HANA Studio.
In the Properties section, choose the Hierarchy tab.
Under the Hierarchy tab, choose the Change button next to the Name area.
Click Browse … and select a hierarchy from the dropdown list.
Use the other options under the Hierarchy tab to adjust the presentation of the hierarchy.
External Hierarchy Properties
Each hierarchy has properties that were determined in the hierarchy definition.
You can change the following hierarchy properties in the query definition.
External Hierarchy Properties
Property | Description |
---|
Position of Child Nodes | Position lower-level nodes above or below a higher-level node. |
Nodes with Only One Child Node | Show or hide nodes with only one lower level node. |
Values of Postable Nodes | Show or hide the values of postable nodes. |
Expand to Level | Determine the level to which the hierarchy is expanded initially in the report |
Sorting | Within the hierarchy, sort members in descending or ascending order by key or text. When using the default option Same as in Hierarchy, you cannot sort in descending or ascending order. |
Characteristic Restrictions with External Hierarchies
Use hierarchies to select filter values for characteristics by selecting individual hierarchy nodes.
To restrict a characteristic to a hierarchy node:
Open the context menu of the characteristic and choose Restrict.
In the Edit Filter dialogue, select the Hierarchy Nodes tab, then select the desired hierarchy nodes or members.
Choose OK to confirm.