query
Execute SQL queries on a profile and retrieve results with pagination. Returns columns, rows, and a cursor to fetch additional pages without re-executing the query.
Instructions
Execute SQL on a profile (default profile when omitted). Returns the first page as compact {"columns":[...],"rows":[[...],...],"page":{"returned","has_more","estimated_rows","cursor"}}. When has_more is true, pass page.cursor to the fetch tool — the query is NOT re-executed; a server-side cursor is held open (stable snapshot). Placeholders: %s positional with the params array.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| sql | Yes | ||
| params | No | ||
| profile | No | ||
| page_size | No |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |