Skip to main content
Glama
questdb

mcp-server-questdb

Official

run_cell

Execute a SQL notebook cell in QuestDB, running statements sequentially and stopping on error. Returns success, query count, and per-statement results. Handles DDL/DML with write permission and consent.

Instructions

Execute a SQL cell. Each ;-separated statement runs sequentially; if one fails, the remaining statements are NOT attempted. Returns { success, queryCount, results: string[] }, where each results entry is "success", "cancelled", or "ERROR: <message>", in source order. You do NOT see columns, rows, or values — call run_query if you need data. success is true only when every statement reached "success". This is the ONLY path that executes agent-initiated DDL/DML in a cell (apply_notebook_state and add_cell never auto-run writes) — it requires the 'write' permission and the user's consent. A markdown cell is never executed: the response is { ran: false, skipped: true, note: <reason> }.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
cell_idYes
buffer_idYes
Behavior5/5

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

With no annotations, the description fully discloses behavior: sequential execution stops on first error, return format with per-statement statuses, markdown cells are skipped, and success is only when all statements succeed. It also mentions the 'write' permission requirement.

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 dense but every sentence provides essential information. It is well-structured, starting with the primary action, then behavioral nuances, return format, alternatives, and special cases.

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

Completeness5/5

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

Given no annotations and no output schema, the description covers return types, failure semantics, skipped markdown behavior, permission requirements, and distinguishes from sibling tools. It is thorough and actionable.

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

Parameters2/5

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

Schema coverage is 0% and the description does not explain the roles of buffer_id and cell_id. While the names are somewhat self-explanatory in context, the description does not compensate for the lack of schema documentation, leaving ambiguity for an agent.

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 tool executes a SQL cell with a specific verb and resource. It further distinguishes itself by noting it is the only path for agent-initiated DDL/DML and contrasts with run_query for data retrieval.

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

Usage Guidelines5/5

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

Explicit guidance is provided: use run_query instead when data results are needed, and note that apply_notebook_state and add_cell never auto-run writes. It also states permission and consent requirements.

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/questdb/mcp-server-questdb'

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