Skip to main content
Glama

preview_query

Execute read-only SELECT queries and CTEs with safety validation and row limits to preview database results before making changes.

Instructions

Execute read-only SELECT statements and CTEs with safety validation and row limits.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
sqlYes
max_rowsNo

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Behavior3/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations provided, the description carries the full burden of behavioral disclosure. It adds useful context about 'safety validation and row limits,' which hints at constraints and safety features, but doesn't detail specific behaviors like error handling, performance limits, or what 'safety validation' entails. This provides some value but lacks comprehensive behavioral traits.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is a single, efficient sentence that front-loads the core purpose ('Execute read-only SELECT statements and CTEs') and adds qualifying details ('with safety validation and row limits'). Every word earns its place, making it highly concise and well-structured without unnecessary elaboration.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given the tool's complexity (SQL execution with safety features), no annotations, and an output schema present, the description is reasonably complete. It covers the main purpose and key constraints, but could benefit from more detail on behavioral aspects like validation specifics or error scenarios, though the output schema mitigates some gaps.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 0%, so the schema provides no parameter details. The description adds minimal semantics by implying 'sql' is for SELECT/CTEs and 'max_rows' relates to row limits, but doesn't explain parameter formats, defaults, or constraints. It partially compensates for the coverage gap but leaves key aspects undocumented.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the specific action ('Execute read-only SELECT statements and CTEs') and the resource (SQL queries), distinguishing it from siblings like 'execute_readonly_sql' by emphasizing safety validation and row limits. It uses precise technical terms that define its scope effectively.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description implicitly guides usage by specifying 'read-only SELECT statements and CTEs,' indicating it's for querying data rather than modifications. However, it doesn't explicitly mention when not to use it (e.g., for INSERT/UPDATE) or name alternatives like 'insert_row' or 'execute_readonly_sql,' leaving some ambiguity in sibling differentiation.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/antonov2010/mcp-dev'

If you have feedback or need assistance with the MCP directory API, please join our Discord server