query
Run a read-only SQLite SELECT to retrieve rows from hospital tables, with results capped at 1,000 rows and a truncated flag. Aggregate in SQL to avoid pulling large raw datasets.
Instructions
Run one read-only SQLite SELECT (or WITH ... SELECT) and get the rows back.
Aggregate in SQL instead of pulling raw rows: the stays table has 151,000 rows. At most 1,000 rows
are returned; truncated says whether more existed. Dates are text in YYYY-MM-DD form, so
strftime('%Y-%m', date) and date BETWEEN '2025-11-01' AND '2026-10-31' work.
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": {
"sql": "<sql>"
},
"name": "query"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| sql | Yes | ||
| limit | No |