Skip to main content
Glama
lm203688

MySQL MCP Server

Execute Write

execute_write

Execute INSERT, UPDATE, or DELETE statements on MySQL/MariaDB databases when read-only mode is disabled. Use for modifying data directly.

Instructions

执行写操作(INSERT/UPDATE/DELETE),需要关闭只读模式

⚠️ 此工具仅在只读模式关闭时可用(MYSQL_MCP_READ_ONLY=false)

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
sqlYesSQL写操作语句(INSERT/UPDATE/DELETE)
databaseNo可选,指定数据库

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4.2/5.0
Behavior4/5

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

With no annotations provided, the description carries the full behavioral burden, and it does disclose the core mutation side effect and the read-only gate. It flags a critical configuration-dependent behavior that an agent must know before calling. It does not detail transaction/commit behavior or destructive-statement impact, which would push it to a 5.

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 two short sentences with no filler. The key warning about read-only mode is front-loaded after the core purpose. Every word contributes to either defining the operation or preventing misuse.

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

Completeness4/5

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

The description covers the purpose, the acceptable SQL statement types, and the critical gating condition, while the output schema handles return values. The main gaps are transactionality and the consequences of destructive statements, but these are secondary given the clear mutation warning. Overall, an agent has enough to select and invoke the tool correctly.

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%, and both parameters already carry descriptive text, so the description adds little beyond the structured schema. The mention of INSERT/UPDATE/DELETE reinforces what the sql parameter accepts, but that same constraint is already in the parameter description. Baseline 3 is appropriate given the full schema coverage.

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 explicitly states the tool executes write operations (INSERT/UPDATE/DELETE), which is a specific verb-resource pairing. This clearly distinguishes it from the read-only siblings such as query and list_tables. The tool is unambiguously the write counterpart in the set.

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?

The description gives a clear precondition: the tool is only available when read-only mode is disabled, with the exact environment variable named. It does not explicitly say 'use query for SELECT', but the restriction to INSERT/UPDATE/DELETE makes the usage boundary clear. This is solid context without an explicit alternatives section.

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