execute_query
Run read-only SQL queries (SELECT, SHOW, DESCRIBE, EXPLAIN, WITH) on PostgreSQL databases, with optional row limits, to retrieve or analyze data securely.
Instructions
Execute a read-only SQL query (SELECT, SHOW, DESCRIBE, EXPLAIN, WITH statements only)
Input Schema
Name | Required | Description | Default |
---|---|---|---|
limit | No | Maximum number of rows to return (default: 100) | |
query | Yes | SQL query to execute (read-only operations only) |
Input Schema (JSON Schema)
{
"$schema": "http://json-schema.org/draft-07/schema#",
"additionalProperties": false,
"properties": {
"limit": {
"description": "Maximum number of rows to return (default: 100)",
"type": "number"
},
"query": {
"description": "SQL query to execute (read-only operations only)",
"type": "string"
}
},
"required": [
"query"
],
"type": "object"
}