You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: advanced/odata.md
-43Lines changed: 0 additions & 43 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1099,49 +1099,6 @@ GET /Order(10)/books?
1099
1099
This query groups the 500 most expensive books by author name and determines the price of the most expensive book per author.
1100
1100
1101
1101
1102
-
### Hierarchical Transformations
1103
-
1104
-
Provide support for hierarchy attribute calculation and navigation, and allow the execution of typical hierarchy operations directly on relational data.
|`com.sap.vocabularies.Hierarchy.v1.TopLevels`| generate a hierarchy based on recursive parent-child source data | <X/><sup>(1)</sup> | <X/><sup>(1)</sup> |
1109
-
|`ancestors`| return all ancestors of a set of start nodes in a hierarchy | <X/><sup>(1)</sup> | <X/><sup>(1)</sup> |
1110
-
|`descendants`| return all descendants of a set of start nodes in a hierarchy | <X/><sup>(1)</sup> | <X/><sup>(1)</sup> |
1111
-
1112
-
- <sup>(1)</sup> Beta feature, API may change
1113
-
1114
-
Generic implementation is supported on the following databases:
1115
-
1116
-
|| SAP HANA | H2 | PostgreSQL | SQLite |
1117
-
|---|---|---|---|---|
1118
-
| CAP Java | ✓ | ✓ |||
1119
-
| CAP Node.js | ✓ ||✓ |✓ |
1120
-
1121
-
:::info
1122
-
The source elements of the entity defining the recursive parent-child relation are identified by a naming convention or aliases `node_id` and `parent_id`.
1123
-
For more refer to [SAP HANA Hierarchy Developer Guide](https://help.sap.com/docs/SAP_HANA_PLATFORM/4f9859d273254e04af6ab3e9ea3af286/f29c70e984254a6f8df76ad84e78f123.html?locale=en-US&version=2.0.05)
The [`TopLevels` transformation](https://github.com/SAP/odata-vocabularies/blob/main/vocabularies/Hierarchy.xml) produces the hierarchical result based on recursive parent-child relationship:
The [`ancestors` and `descendants` transformations](https://docs.oasis-open.org/odata/odata-data-aggregation-ext/v4.0/cs03/odata-data-aggregation-ext-v4.0-cs03.html#Transformationsancestorsanddescendants) compute the subset of a given recursive hierarchy, which contains all nodes that are ancestors or descendants of a start nodes set. Its output is the ancestors or descendants set correspondingly.
0 commit comments