Skip to content

Commit 221e7a7

Browse files
committed
Removed section OData hierarchical transformation -> this is not public!
1 parent 3c37c19 commit 221e7a7

File tree

1 file changed

+0
-43
lines changed

1 file changed

+0
-43
lines changed

advanced/odata.md

Lines changed: 0 additions & 43 deletions
Original file line numberDiff line numberDiff line change
@@ -1099,49 +1099,6 @@ GET /Order(10)/books?
10991099
This query groups the 500 most expensive books by author name and determines the price of the most expensive book per author.
11001100

11011101

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.
1105-
1106-
| Transformation | Description | Node.js | Java |
1107-
|-----------------------------------------------|------------------------------------------------------------------|:-------:|:------------------:|
1108-
| `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)
1124-
:::
1125-
1126-
#### `com.sap.vocabularies.Hierarchy.v1.TopLevels`
1127-
1128-
The [`TopLevels` transformation](https://github.com/SAP/odata-vocabularies/blob/main/vocabularies/Hierarchy.xml) produces the hierarchical result based on recursive parent-child relationship:
1129-
1130-
```http
1131-
GET /SalesOrganizations?$apply=
1132-
com.sap.vocabularies.Hierarchy.v1.TopLevels(..., NodeProperty='ID', Levels=2)
1133-
```
1134-
#### `ancestors` and `descendants`
1135-
1136-
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.
1137-
1138-
```http
1139-
GET SalesOrganizations?$apply=
1140-
descendants(..., ID, filter(ID eq 'US'), keep start)
1141-
/ancestors(..., ID, filter(contains(Name, 'New York')), keep start)
1142-
```
1143-
1144-
11451102
### Aggregation Methods
11461103

11471104
| Aggregation Method | Description | Node.js | Java |

0 commit comments

Comments
 (0)