Skip to main content
Glama
Baronco

SQL-Transpiler MCP Tool

by Baronco

πŸš€ SQL-Transpiler MCP Tool

SQL-Transpiler is a MCP tool designed to transpile SQL queries between different dialects using the sqlglot library. This tool helps you convert SQL code from one dialect (e.g., MySQL) to another (e.g., PostgreSQL) with ease, ensuring compatibility across various database systems.


πŸ› οΈ Features

  • Dialect Support: Lists all SQL dialects supported by sqlglot.

  • SQL Transpilation: Converts SQL queries from one dialect to another.

  • Error Handling: Informs you if a dialect is unsupported or if there are syntax errors.


Related MCP server: Python MSSQL MCP Server

πŸ“¦ Library Used

  • sqlglot
    Version: Check your pyproject.toml or uv.lock for the exact version used in this project.


βš™οΈ Prerequisites

  • Python 3.13+ (if running locally)

  • UV package manager (for dependency management)

  • Docker (if running via container)


πŸš€ Installation

Option 1: Using UV (Locally)

  1. Clone the repository

    git clone https://github.com/Baronco/SQL-Transpiler-MCP-Tool.git
    cd sql-transpiler
  2. Install UV

    pip install uv
  3. Sync dependencies (using uv.lock)

    uv sync --frozen
  4. Run the server

    uv run server.py

Option 2: Using Docker

  1. Clone the repository

    git clone https://github.com/your-username/sql-transpiler.git
    cd sql-transpiler
  2. Build the Docker image

    docker build -t sql-transpiler .

πŸ“„ Usage

  • Use the Dialects tool to list all supported SQL dialects.

  • Use the Transpiler tool to convert SQL queries from one dialect to another.

For more details, see the instructions in src/instructions.md.

πŸ–₯️ Integration with Claude Desktop

To add the SQL-Transpiler MCP tool to your Claude Desktop configuration using the Docker image, update your claude_desktop_config.json as follows:

{
  "mcpServers": {
    "sql-transpiler": 
    {
      "command": "docker",
      "args": ["run", "-i", "--rm", "--init", "-e", "DOCKER_CONTAINER=true", "sql-transpiler"]
    }
  }
}

If you want to use your local environment with UV instead of Docker, configure your claude_desktop_config.json like this (adjust the path as needed):

{
  "mcpServers": {
    "sql-transpiler": 
    {
      "command": "uv",
      "args": [
        "--directory",
        "path/to/sql-transpiler",
        "run",
        "server.py"
      ]
    }
  }
}

πŸ“ License

MIT License

Available Tools

2 tools
DialectsB

List all available SQL dialects supported by sqlglot.

ParametersJSON Schema
NameRequiredDescriptionDefault

No parameters

TDQS

B3.4/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 indicates a read-only listing operation ('List all available SQL dialects'), which implies no destructive actions, but does not disclose details like rate limits, authentication needs, or output format. The description adds basic behavioral context but lacks depth for a tool with no 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?

The description is a single, efficient sentence that directly states the tool's purpose without unnecessary words. It is front-loaded and appropriately sized for a simple listing tool, with zero waste.

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 the tool's simplicity (0 parameters, no output schema, no annotations), the description is adequate but minimal. It covers the basic purpose but lacks details on output format or behavioral traits, which could be helpful for an agent despite the low complexity. It meets minimum viability with clear gaps in completeness.

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 tool has 0 parameters, and the schema description coverage is 100%, so no parameter information is needed. The description does not add parameter semantics, but this is acceptable given the absence of parameters, warranting a baseline score of 4.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the verb ('List') and resource ('all available SQL dialects supported by sqlglot'), making the purpose specific and understandable. However, it does not explicitly differentiate from the sibling tool 'Transpiler', which might handle SQL translation rather than listing dialects.

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?

The description provides no guidance on when to use this tool versus the sibling 'Transpiler', nor does it mention any prerequisites or alternative contexts. It lacks explicit usage instructions, leaving the agent to infer based on tool names alone.

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

TranspilerA

Transpile SQL queries from one dialect to another using sqlglot. First, run the Dialects tool to check if both the source and target dialects are supported.

ParametersJSON Schema
NameRequiredDescriptionDefault
sql_queryYesThe SQL query to transpile.
from_dialectYesThe dialect of the input SQL query.
to_dialectYesThe target dialect for the output SQL query.

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 mentions the underlying library (sqlglot) and a prerequisite check, which adds useful context. However, it lacks details on error handling, performance, or output format (e.g., whether it returns a string or structured data), leaving behavioral gaps for a tool with no 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?

The description is two sentences with zero waste: the first states the core purpose, and the second provides essential usage guidance. It is front-loaded with the main action and efficiently includes only necessary information.

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 no annotations and no output schema, the description is moderately complete. It covers purpose and usage prerequisites but lacks details on output (e.g., what the transpiled query looks like) and error cases (e.g., unsupported dialects). For a tool with 3 parameters and no structured output info, more behavioral context would be beneficial.

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 fully documents all three parameters. The description does not add any parameter-specific details beyond what the schema provides (e.g., no examples of dialect values or query formatting). Baseline 3 is appropriate as the schema handles the heavy lifting.

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 clearly states the specific action ('transpile SQL queries from one dialect to another') and the resource ('SQL queries'), using the verb 'transpile' which is precise. It distinguishes from the sibling 'Dialects' tool by mentioning it as a prerequisite check rather than a direct alternative, establishing clear functional separation.

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?

The description explicitly provides usage guidance: 'First, run the Dialects tool to check if both the source and target dialects are supported.' This gives a clear prerequisite step and references the sibling tool, indicating when to use it (before this tool) and why (to verify dialect support).

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

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections. Dates show when Glama detected each change.

  1. 2 tool updates
    • First observedDialects
    • First observedTranspiler

TDQS

A3.7/5.0
Disambiguation5/5

The two tools have perfectly distinct purposes: Dialects lists available SQL dialects, while Transpiler converts queries between dialects. There is no overlap in functionality, and the descriptions clearly differentiate their roles, making misselection impossible.

Naming Consistency5/5

Both tools use clear, descriptive noun-based names (Dialects and Transpiler) that align with their functions. While not following a strict verb_noun pattern, they are consistently styled and immediately understandable within the server's domain.

Tool Count3/5

With only two tools, the server feels thin for its stated purpose of SQL transpilation. While the tools cover core functionality (listing dialects and transpiling), additional tools for validation, parsing, or error handling could enhance completeness. The count is borderline but workable.

Completeness3/5

The tools cover the essential workflow of checking dialects and transpiling queries, but there are notable gaps. Missing operations include validating SQL syntax, optimizing queries, or handling errors during transpilation. The surface is functional but minimal, potentially requiring workarounds for advanced use cases.

Maintenance

ActivityInactive
ResponsivenessNo issues

Resources

Unclaimed servers have limited discoverability.

Looking for Admin?

If you are the server author, to access and configure the admin panel.

Related MCP Connectors

Related MCP Servers

  • A
    license
    A
    quality
    C
    maintenance
    Enables interaction with Microsoft SQL Server databases through a Model Context Protocol interface, supporting database connections, switching between databases, and executing secure SELECT queries.
    8
    22
    MIT
  • F
    license
    Not graded
    quality
    D
    maintenance
    Enables Language Models to interact with Microsoft SQL Server databases by inspecting table schemas, executing SQL queries, and reading table data through a standardized Model Context Protocol interface.
    27
    -
  • A
    license
    Not graded
    quality
    D
    maintenance
    Translates natural language to SQL/GraphQL queries and executes them, enabling AI agents to interact with databases through the Model Context Protocol.
    1
    Apache 2.0
  • F
    license
    A
    quality
    D
    maintenance
    Enables AI assistants to query SQL Server databases and retrieve schema information securely through the Model Context Protocol.
    2
    -

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/Baronco/SQL-Transpiler-MCP-Tool'

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