MCP.so
ログイン

Jewei Mysql MCP Server

@jeweis

基本情報

カテゴリ

データベース

トランスポート

stdio

作者

jeweis

投稿者

jewei

Jewei Mysql MCP Server について

# MySQL MCP Server

#mysql#mysql-mcp

Jewei Mysql MCP Server の設定

以下の設定を使って、このサーバーを MCP 対応クライアントに追加してください。

{
  "mcpServers": {
    "jewei-mysql": {
      "disabled": false,
      "command": "uvx",
      "args": [
        "jewei-mysql-mcp-server"
      ],
      "env": {
        "DB_HOST": "your_db_host",
        "DB_USER": "your_db_user",
        "DB_PASSWORD": "your_db_password",
        "DB_NAME": "your_db_name",
        "DB_PORT": "your_db_port"
      }
    }
  }
}

Jewei Mysql MCP Server のツール

4

执行SQL查询并返回结果集(仅支持SELECT语句) Args: sql: SQL查询语句(必须是SELECT语句) Returns: 包含查询结果的字典,格式为: { "columns": [列名列表], "rows": [行数据列表], "row_count": 结果行数 }

获取指定表的结构信息 Args: table_name: 表名 schema: 数据库名,默认为当前数据库 Returns: 包含表结构信息的字典,格式为: { "columns": [列信息列表], "primary_keys": [主键列表], "foreign_keys": [外键信息列表], "indexes": [索引信息列表] }

列出数据库中的所有表 Args: schema: 数据库名,默认为当前数据库 Returns: 包含表列表的字典,格式为: { "tables": [表信息列表], "count": 表数量 }

获取数据库基本信息 Returns: 包含数据库信息的字典,格式为: { "database_name": 当前数据库名, "version": 数据库版本, "schemas": [数据库列表], "connection": { "host": 主机名, "port": 端口, "database": 数据库名, "user": 用户名 } }

概要

What is Jewei Mysql Mcp Server?

Jewei Mysql Mcp Server is a MySQL database query server that executes SQL queries (only SELECT statements), retrieves table structure information (columns, primary keys, foreign keys, indexes), and lists all tables in a database. It is designed for developers who need to interact with MySQL databases through MCP-compatible tools like Windsurf, Cursor, Claude, or Cline.

How to use Jewei Mysql Mcp Server?

Install dependencies with pip install -r requirements.txt, create a .env file with the environment variables DB_HOST, DB_PORT, DB_USER, DB_PASSWORD, and DB_NAME, then run using uvx --from jewei-mysql-mcp-server jewei-mysql-mcp-server (recommended) or from source with python -m jewei_mysql_mcp_server.server. Configure the server in MCP config files for supported clients, replacing placeholder values with your actual database connection info.

Key features of Jewei Mysql Mcp Server

  • Execute SQL queries and return result sets (SELECT only)
  • Get detailed table structure including columns, keys, and indexes
  • List all tables in the specified database
  • Supports MCP integration with Windsurf, Cursor, Claude, and Cline
  • Run via uvx for easy installation and execution

Use cases of Jewei Mysql Mcp Server

  • Query a MySQL database using SELECT statements through MCP clients
  • Explore database schema by listing tables and viewing table structure
  • Integrate MySQL database interactions into AI-assisted development workflows

よくある質問

1

What queries does Jewei Mysql Mcp Server support?

Only SELECT statements are supported. INSERT, UPDATE, DELETE, and other SQL commands are not allowed.

2

How do I configure the database connection for Jewei Mysql Mcp Server?

Set the environment variables DB_HOST, DB_PORT, DB_USER

コメント

「データベース」の他のコンテンツ