MCP queries and schema inspection for legacy MySQL 5.0–5.6, with opt-in INSERT/UPDATE/DELETE/DDL; verified live against each version.
mysql-legacy-mcp demonstrates solid foundational quality with 11 well-defined tools covering a coherent domain (MySQL 5.0-5.6 introspection and DML). All tools have names, descriptions, and explicit input schemas registered via z.string() and parameter descriptors. Tool annotations (readOnlyHint, destructiveHint, idempotentHint) are present and properly applied. However, several patterns are underexploited: output schemas are not formally documented in the tool definitions; parameter descriptions are minimal and sometimes vague (e.g., 'A SELECT query' lacks detail on behavior/constraints); error messages are generic; and no confirmation/dry-run patterns exist for destructive operations. The server excels at naming clarity (mysql_legacy_* prefix is explicit) and composition (one tool per responsibility), but falls short on LLM-friendly descriptions (many under 100 chars) and output documentation. No pagination guidance or result-limiting descriptions for list operations.
Execute a DDL query: CREATE, ALTER, DROP, TRUNCATE, or RENAME (table-level only; database-level DDL is rejected). Requires MYSQL_LEGACY_ALLOW_DDL=true.
Execute a DELETE query with a WHERE clause. DELETE without WHERE is rejected. Requires MYSQL_LEGACY_ALLOW_DELETE=true.
Describe table schema: columns, types, collations, null constraints, defaults, and keys. Use mysql_legacy_show_create_table for full CREATE TABLE statement and mysql_legacy_list_indexes for index details.
Execute an INSERT query. Requires MYSQL_LEGACY_ALLOW_INSERT=true.
List all databases, optionally including system databases (information_schema, mysql)
List all indexes on a table. Use mysql_legacy_describe_table for column constraints and mysql_legacy_show_create_table for the full CREATE TABLE statement.
Output schemas not formally documented. Tool definitions include descriptions but no explicit documentation of response structure (field names, types, cardinality). LLMs cannot reliably plan multi-step sequences or parse results without knowing what fields to expect.
Parameter descriptions are sparse and lack operational detail. E.g., mysql_legacy_select accepts 'sql' with only 'A SELECT query (exactly one statement, up to 100,000 characters)' but omits behavior constraints (result truncation limits, forbidden features, parsing restrictions). LLMs cannot infer row/byte limits or error recovery strategies.
| Scored | Grade | Overall | Spec posture | Rubric |
|---|---|---|---|---|
| 2026-09-23 | C | 63 | 2026-07-28+ | v2 |
List all tables and views in a database
Check connection and retrieve server version information
Execute a SELECT query. Rows are returned in JSON; large result sets are truncated by row count or byte size. Results are limited to MYSQL_LEGACY_MAX_ROWS (default 200) and MYSQL_LEGACY_MAX_RESULT_BYTES (default 256 KiB). Locking reads (FOR UPDATE, LOCK IN SHARE MODE) and SELECT ... INTO are rejected. For bulk export, use mysql_legacy_ddl with a CREATE TABLE AS SELECT or similar, then fetch rows in chunks.
Retrieve the CREATE TABLE statement for a table, parsed to extract charset and engine. Compare columns and indexes against mysql_legacy_describe_table and mysql_legacy_list_indexes for full structural details.
Execute an UPDATE query with a WHERE clause. UPDATE without WHERE is rejected. Requires MYSQL_LEGACY_ALLOW_UPDATE=true.
No dry-run or confirmation pattern for destructive operations (INSERT, UPDATE, DELETE, DDL). Agents cannot preview changes before committing. Combined with permission-gating via environment variables (not per-agent), this risks unintended mutations.
Error handling lacks recovery guidance. Validation errors (e.g., forbidden SELECT features, missing WHERE clause) throw raw error messages with no hint on what to try next. LLMs receive 'locking read ... is not allowed' but no guidance to retry without the locking clause.
List operations (mysql_legacy_list_databases, mysql_legacy_list_tables, mysql_legacy_list_indexes) do not document pagination or result limits. Descriptions mention no constraint on row count returned. Large schemas risk context explosion without documented limits or pagination parameters.
Permission model is coarse-grained (MYSQL_LEGACY_ALLOW_INSERT/UPDATE/DELETE/DDL environment variables). All-or-nothing gates do not support per-agent or per-user permissions, limiting multi-tenant or multi-agent deployments.