Book Image

Software Development on the SAP HANA Platform

By : Mark Walker
Book Image

Software Development on the SAP HANA Platform

By: Mark Walker

Overview of this book

Table of Contents (19 chapters)
Software Development on the SAP HANA Platform
Credits
About the Author
About the Reviewers
www.PacktPub.com
Preface
Index

Hierarchy types in SAP HANA


SAP HANA can use two different types of hierarchy:

  • Parent-child hierarchy

  • Level hierarchy

Let's take a couple of minutes to look at these hierarchy types.

Parent-child hierarchies

A parent-child hierarchy is a simple, two-level hierarchy where the child element has an attribute containing the parent element. This hierarchy type is somewhat limited (to two levels, for example), though it does have some use in specific circumstances.

You might consider that an invoice having several lines is a parent-child hierarchy, where the invoice ID is the parent and the line item is the child, for example.

Level hierarchies

A level hierarchy, as its name suggests, does not limit the hierarchy to only two levels, making it much more flexible in terms of how many levels of data you can represent with one. You can define freely the hierarchy levels, as long as each child node has the parent node as an attribute. This allows us to create several different levels, where one node's child...