Skip to main content
Glama
neverinfamous

MySQL MCP Server

MySQL SUBSTRING

mysql_substring
Read-only

Extract substrings from column values in MySQL tables with specified start position and length. Optionally filter rows and include the source column for context.

Instructions

Extract substrings from column values.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
colNoAlias for column
nameNoAlias for table
limitNoMaximum number of rows to return
startNoStarting position (1-indexed)
tableNoTable name (Note: Pass a table name, not a raw string)
whereNoAdditional WHERE clause for filtering
columnNoColumn name (Note: Pass a column name, not a raw string)
filterNoAlias for where
lengthNoNumber of characters
tableNameNoAlias for table
includeSourceColumnNoInclude source column in output (default: false). Set to true for full context.

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
codeNoError code (e.g. VALIDATION_ERROR, QUERY_ERROR)
dataNo
errorNoError message if operation failed
detailsNoAdditional error context
metricsNoToken estimation metrics
successYesWhether the operation succeeded
categoryNoError category (validation, query, connection, internal)
suggestionNoSuggested fix for the error
recoverableNoWhether the error is recoverable
Behavior3/5

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

Annotations already declare readOnlyHint=True and destructiveHint=False, establishing it as a safe read operation. The description adds no further behavioral details (e.g., behavior on invalid positions, return format). It does not contradict annotations.

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

Conciseness2/5

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

The description is a single short sentence, which is concise but under-specified. With 11 parameters and multiple aliases, more structure (e.g., noting required parameters, example usage) would improve usability without losing conciseness.

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?

Given the tool's complexity (11 parameters, aliases, output schema), the description is too minimal. It does not explain how to use key parameters like 'start', 'length', or the 'includeSourceColumn' flag, leaving the agent to rely solely on parameter descriptions.

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 schema already documents parameter meanings. The description adds no additional semantics beyond the schema, such as clarifying relationships between parameters like 'start' and 'length' or the fact that 'start' is 1-indexed.

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 'Extract substrings from column values' clearly states the action (extract substrings) and the target (column values). It distinguishes this tool from sibling tools like mysql_concat or mysql_like_search, which perform different string operations.

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 alternatives like mysql_regexp_match or mysql_like_search. There is no mention of prerequisites, context, or cases where this tool is not appropriate.

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/neverinfamous/mysql-mcp'

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