rewrite_connection_string
Replace a literal substring in a .pbix's DataMashup to update connection strings, clearing permission bindings, and return the number of replacements.
Instructions
Find/replace a literal substring (a server/db name, file path, URL, ...) across Section1.m inside a .pbix's DataMashup, clearing PermissionBindings. Returns how many occurrences were replaced. RISKY - work on a COPY; the .pbix must be CLOSED in Desktop; refuses protected client paths.
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": {
"pbixPath": "<pbixPath>",
"find": "<find>",
"replace": "<replace>"
},
"name": "rewrite_connection_string"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| find | Yes | the literal substring to find | |
| replace | Yes | the replacement substring | |
| pbixPath | Yes | absolute path to the .pbix (a COPY) |