add_dataset_field
Appends a data-bound field to a Power BI dataset's Fields block to declare a query column not yet present. Refuses duplicates.
Instructions
Append a data-bound to a dataset's block. Writes data_field (and optional rd:TypeNametype_name</rd:TypeName>). Distinct from add_calculated_field which writes for derived fields. Use after rewriting the DAX to declare a new column that came back from the query but isn't yet in . Refuses on duplicate field name.
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": {
"path": "<path>",
"dataset_name": "<dataset_name>",
"field_name": "<field_name>",
"data_field": "<data_field>"
},
"name": "add_dataset_field"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| path | Yes | ||
| type_name | No | .NET type, e.g. 'System.String', 'System.DateTime', 'System.Decimal'. Optional. | |
| data_field | Yes | Source column reference, e.g. 'Sales[ProductID]' or '[Region]' (the form depends on DAX shape). | |
| field_name | Yes | ||
| dataset_name | Yes |