add_hierarchy_level
Add a level to an existing hierarchy from a column on the same table in Power BI. Optionally set its position within the hierarchy and a display name.
Instructions
Add a level to an existing hierarchy from a column on the same table. ordinal positions it (0 = top; omitted = appended at the bottom); remaining levels are renumbered densely.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"sessionId": "<sessionId>",
"table": "<table>",
"hierarchy": "<hierarchy>",
"column": "<column>"
},
"name": "add_hierarchy_level"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| table | Yes | ||
| column | Yes | the column backing the new level | |
| ordinal | No | position within the hierarchy, 0 = top (optional; default = bottom) | |
| hierarchy | Yes | the hierarchy to extend | |
| levelName | No | level display name (optional; defaults to the column name) | |
| sessionId | Yes |