Database Query
Database Query
ToolIntermediateExecute SQL queries against connected databases with parameterization and result formatting.
Databasedatabasesqlquerydata
When to Use
Use for agents that need to read from or write to databases. Supports PostgreSQL, MySQL, and SQLite. Always uses parameterized queries for security.
Usage Conditions
- Data needs to be retrieved from a database
- Records need to be created, updated, or deleted
- Complex data aggregations are required
Parameter Schema
| Name | Type | Required | Description |
|---|---|---|---|
| query | string | SQL query to execute | |
| params | array | Query parameters for safe substitution | |
| database | string | Target database connection name |
Implementation Notes
# Database Query Tool ## Purpose Safely execute SQL queries against connected databases. ## Security - Parameterized queries only (no string concatenation) - Read-only mode available - Query timeout limits - Result row limits ## Supported Databases - PostgreSQL - MySQL / MariaDB - SQLite - Supabase, Neon, PlanetScale
Generated JSON Schema
{
"type": "object",
"name": "Database Query",
"geneType": "tool",
"parameters": {
"query": { "type": "string", "required": true },
"params": { "type": "array" },
"database": { "type": "string" }
}
}