Skip to main content
Glama
Rufflet

mysql-legacy-mcp

mysql_legacy_select

Read-onlyIdempotent

Execute a single read-only SELECT on legacy MySQL servers, with enforced row/byte limits and read-only transactions for safe querying.

Instructions

Runs exactly one SELECT supplied in sql. Rejects SELECT INTO and locking reads; truncates by MYSQL_LEGACY_MAX_ROWS and MYSQL_LEGACY_MAX_RESULT_BYTES. On MySQL 5.6.5+ wraps in START TRANSACTION READ ONLY unless MYSQL_LEGACY_DISABLE_READ_ONLY_TRANSACTIONS=true. For columns use mysql_legacy_describe_table; for CREATE TABLE text use mysql_legacy_show_create_table; for writes use mysql_legacy_insert, mysql_legacy_update, or mysql_legacy_delete.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
sqlYesOne MySQL 5.1-compatible SELECT statement.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4.9/5.0
Behavior5/5

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

Beyond the readOnly/idempotent/not-destructive annotations, it discloses result truncation via two environment variables, the read-only transaction wrapping on MySQL 5.6.5+, and the disable flag. These are non-obvious behaviors that materially affect results and are not visible in the schema or annotations.

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 dense sentences, each carrying distinct information: operation constraints, behavior/transaction semantics, and sibling routing. No filler or repetition of annotation or schema content.

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 the single-parameter schema, existing annotations, and the absence of an output schema, the description covers what SQL is allowed, how results are bounded, transaction behavior, and when to use sibling tools. An agent has enough to select and invoke this tool safely and correctly.

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?

Schema coverage is 100% for the single sql parameter, but the description enriches the parameter semantics by specifying it must be exactly one SELECT, rejecting SELECT INTO and locking reads, and noting MySQL 5.1 compatibility. This goes beyond the schema's one-line description, though the schema already carried the core type and length constraints.

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 states a specific verb ('Runs') with a precise resource ('exactly one SELECT supplied in sql') and immediately distinguishes itself from siblings by rejecting SELECT INTO and locking reads. It clearly identifies this as the SELECT tool among the mysql_legacy_* siblings.

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?

It gives explicit routing: use mysql_legacy_describe_table for columns, mysql_legacy_show_create_table for CREATE TABLE, and insert/update/delete for writes. It also explains exclusions (SELECT INTO/locking reads), so an agent knows exactly when this tool is and is not appropriate.

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