Skip to main content
Glama

export_data

Exports SQL query results to CSV or JSON files using a specified database connection. Supports row limits and optional headers.

Instructions

Export query results to various formats (CSV, JSON, etc.)

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
queryYesThe SQL query to execute for export (SELECT only)
formatNoExport format (csv or json)csv
maxRowsNoMaximum number of rows to export
connectionIdYesThe ID or name of the database connection
includeHeadersNoInclude column headers in export
Behavior2/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 only states 'Export query results' without explaining whether the query is executed, whether a file is written, what the return value is, or that only SELECT statements are allowed. No mention of the maxRows limit or potential mutating side effects leaves significant ambiguity.

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

Conciseness4/5

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

The description is a single concise sentence that front-loads the key action and formats. It contains no fluff, but it could arguably earn its place more by including a critical constraint (e.g., SELECT-only or maxRows), though for pure conciseness it is well-structured.

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

Completeness2/5

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

This tool has 5 parameters, no annotations, and no output schema, yet the description offers only a high-level summary. It fails to explain what the tool returns (file path, raw bytes, success message), the SELECT-only restriction, the maxRows cap, or any behavioral nuances. For a tool with this complexity, the description is incomplete.

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 100%, so the input schema already documents all parameters fully. The description adds no additional parameter semantics beyond what the schema provides (e.g., it mentions CSV/JSON, but the schema already enumerates these in the format field). Baseline 3 is appropriate.

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

Purpose4/5

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

The description clearly identifies the tool's function: 'Export query results to various formats (CSV, JSON, etc.)' with a specific verb (export) and resource (query results). It implicitly differentiates from siblings like execute_query by focusing on formatted output, but does not explicitly name or contrast with those alternatives.

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

Usage Guidelines2/5

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

No guidance is provided on when to use this tool versus siblings such as execute_query, write_query, or explain_query. The description does not mention prerequisites, limitations (SELECT-only, maxRows), or scenarios where this tool is preferred or discouraged.

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/sangamkotalwar/omnisql-mcp'

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