SQL-Transpiler MCP Tool
Provides tools to transpile SQL queries between MySQL and other supported dialects, ensuring query compatibility across different database environments.
Provides tools to transpile SQL queries between PostgreSQL and other supported dialects, ensuring query compatibility across different database environments.
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@SQL-Transpiler MCP Tool Convert this MySQL query to PostgreSQL: SELECT * FROM users LIMIT 10"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
🚀 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: TextQL MCP Server
📦 Library Used
sqlglot
Version: Check yourpyproject.tomloruv.lockfor 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)
Clone the repository
git clone https://github.com/Baronco/SQL-Transpiler-MCP-Tool.git cd sql-transpilerInstall UV
pip install uvSync dependencies (using
uv.lock)uv sync --frozenRun the server
uv run server.py
Option 2: Using Docker
Clone the repository
git clone https://github.com/your-username/sql-transpiler.git cd sql-transpilerBuild the Docker image
docker build -t sql-transpiler .
📄 Usage
Use the
Dialectstool to list all supported SQL dialects.Use the
Transpilertool 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 toolsDialectsB
List all available SQL dialects supported by sqlglot.
Inputs: no named parameters.
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.
Inputs: sql_query (required), from_dialect (required), to_dialect (required).
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
TDQS
Scored across 2 tools
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.
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.
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.
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
Related MCP Connectors
SQL validation, formatting, parsing, metadata extraction, linting, and security analysis.
Query Postgres, MySQL, SQL Server, Oracle, BigQuery, ClickHouse and Redshift from your AI client.
PostgreSQL, MySQL, and SQL Server in one session. 26 read-only MCP tools for AI agents.
The grounded data layer for any LLM: governed SQL, metrics, lineage and catalog over your data.
Related MCP Servers
- FlicenseNot gradedqualityDmaintenanceEnables 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-
- AlicenseNot gradedqualityDmaintenanceTranslates natural language to SQL/GraphQL queries and executes them, enabling AI agents to interact with databases through the Model Context Protocol.1Apache 2.0
- AlicenseAqualityDmaintenanceEnables AI assistants to query, analyze, and manage SQL Server databases through natural language via the Model Context Protocol.61MIT
- -licenseNot gradedqualityAmaintenanceEnables connecting to and querying SQL Server databases via the Model Context Protocol, with support for managing multiple named connections and automatic configuration of AI clients.-