Skip to main content
Glama
joyous-coder

universal-db-mcp

by joyous-coder

export_table_csv

Export a database table or custom SQL query to a CSV file. Choose table or SQL, plus optional filters and output path.

Instructions

导出单表 (或自定义 SQL) 到 CSV 文件。table 与 sql 二选一;省略 outputPath 时默认写到 /sql/<表名>.csv。profileName 可选 — 省略时使用当前活跃连接。[group: data-governance]

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
sqlNo可选 (与 table 二选一)。自定义 SELECT SQL,用于 Oracle/DM 等方言或带分页的查询。原样执行,不附加 LIMIT/OFFSET。
tableNo可选 (与 sql 二选一)。schema.table 格式,例如 "BBZ_CQ.MD_PERIOD_TYPE"
whereNo
columnsNo
orderByNo
outputPathNo可选。省略时默认 <cwd>/sql/<table-sanitized>.csv (table 模式) 或 <cwd>/sql/query-<时间戳>.csv (sql 模式)。需要 cwd 在 DB_ALLOWED_FILE_PATHS 白名单里。
profileNameNo可选。省略则使用当前活跃连接。

Schema Changelog

Changes observed during successful MCP inspections. Dates show when Glama detected each change.

  1. First observedv5.0.2

TDQS

A4.1/5.0
Behavior3/5

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

No annotations are provided, so the description carries the full burden. It discloses the default output path and active-connection fallback, which is useful. However, it does not state whether existing files are overwritten, what permissions are needed, or what the tool returns on success/failure.

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?

Three compact sentences with no wasted words. The primary action and constraints are front-loaded, and the optional/fallback behavior is packed efficiently.

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

Completeness3/5

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

Given seven parameters, zero annotations, and no output schema, the description is not fully complete: where/columns semantics, overwrite behavior, and return shape are missing. The schema fills in some details (SQL executed as-is, path whitelist), but important gaps remain.

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

Parameters4/5

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

The description adds meaning beyond the schema by stating table/sql exclusivity and the default output naming convention, and it notes profileName fallback. Schema coverage is moderate (57%), so this compensation matters; however, where and columns remain largely unexplained.

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?

States a specific verb and resource: exports a single table or custom SQL result to a CSV file. This clearly distinguishes it from siblings like execute_query (query only), import_csv (import), and export_profiles/export_backup (other export targets).

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?

Gives explicit usage context: table and sql are mutually exclusive, sql is intended for Oracle/DM dialects or paginated queries, and outputPath/profileName have clear fallback behavior. It does not name alternatives from the sibling list, but the internal routing guidance is strong.

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

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/joyous-coder/universal-db-mcp'

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