sql_run_write
Execute write SQL statements like INSERT, UPDATE, DELETE, or DDL. Requires a dry-run preview first, then explicit confirmation to apply changes.
Instructions
Execute a write SQL statement (INSERT, UPDATE, DELETE, DROP TABLE, ALTER TABLE, CREATE, TRUNCATE, EXEC stored proc, etc.).
IMPORTANT PERMISSION RULE:
When
confirmis false (default): returns a DRY-RUN PREVIEW — nothing is executed.When
confirmis true: actually executes the statement.
Always call with confirm=false first to show the user what will happen, then call again with confirm=true only after the user explicitly approves.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| sql | Yes | The SQL statement to execute (INSERT/UPDATE/DELETE/DDL/EXEC etc.) | |
| confirm | No | Set to true ONLY after the user has seen the preview and explicitly approved execution. Default: false. |