db-mcp-tool
データベースエクスプローラーMCPツール
PostgreSQL、MySQL、Firestore などのさまざまな種類のデータベースを探索および管理するための強力なモデル コンテキスト プロトコル (MCP) ツール。
特徴
複数のデータベースのサポート
PostgreSQL
MySQL
ファイアストア
データベース操作
データベースに接続する
テーブルの一覧
トリガーを表示
リスト関数
SQLクエリを実行する(PostgreSQLとMySQL)
テーブルスキーマをエクスポートする
テーブルデータをエクスポートする
Related MCP server: Database MCP Server
カーソルとの統合
ツールをカーソルに追加する前に、プロジェクトをビルドする必要があります。
リポジトリをクローンする
依存関係をインストールします:
npm installプロジェクトをビルドします。
npm run build
ツールをカーソルに追加するには:
カーソル設定を開く
「モデルコンテキストプロトコル(MCP)」セクションに移動します
「新しいツールを追加」をクリックします
以下の詳細を入力してください。
{ "name": "database-explorer", "command": "node /path/to/project/dist/index.js", "description": "Database Explorer MCP Tool" }注:
/path/to/projectプロジェクト ディレクトリへの実際のパスに置き換えます。設定を保存する
カーソルを再開
ツールの使用:
セットアップ後、次のいずれかのコマンドを使用してデータベースに接続できます。
PostgreSQLの場合: 接続の詳細を指定した
!pgを使用するMySQLの場合: 接続詳細に
!mysqlを使用するFirestoreの場合: 接続の詳細とともに
!firestoreを使用します
接続すると、さまざまなデータベース操作を使用できるようになります。
すべての
!tablesトリガーを表示するには
!triggers関数をリストするには
!functions!queryでSQLクエリを実行するテーブルスキーマをエクスポートするには
!export-db!export-dataでテーブルデータをエクスポートする
詳細な使用例については、以下のコマンドのセクションを参照してください。
コマンド
接続コマンド
!pg- PostgreSQLデータベースに接続する{ "connection": { "host": "hostname", "port": 5432, "database": "dbname", "user": "username", "password": "password" } }!mysql- MySQLデータベースに接続する{ "connection": { "host": "hostname", "port": 3306, "database": "dbname", "user": "username", "password": "password" } }!firestore- Firestore データベースに接続する{ "connection": { "projectId": "your-project-id", "keyFilename": "path/to/keyfile.json" } }
データベース操作コマンド
!tables- 接続されたデータベース内のすべてのテーブルを一覧表示します!triggers- 接続されたデータベース内のすべてのトリガーを一覧表示します!functions- 接続されたデータベース内のすべての関数を一覧表示します!query- SQLクエリを実行する(PostgreSQLとMySQLのみ){ "query": "SELECT * FROM table_name" }!export-db- テーブルスキーマをエクスポートする{ "table": "table_name" }!export-data- テーブルデータをINSERT文としてエクスポートする{ "table": "table_name" }
要件
Node.js
必要なデータベース ドライバー:
PostgreSQLの
pgMySQL 用の
mysql2Firestore の
@google-cloud/firestore
使用法
必要なデータベース資格情報があることを確認してください
適切な接続コマンドを使用してデータベースに接続します
利用可能なコマンドを使用してデータベースを探索および管理します
エラー処理
このツールには、次の包括的なエラー処理が含まれています。
接続失敗
クエリ実行エラー
スキーマとデータのエクスポートの問題
無効なデータベース操作
注記
Firestore のサポートは、NoSQL の性質上、基本的な操作に限定されています。
SQL操作はPostgreSQLとMySQLでのみ利用可能です
Available Tools
9 tools!export-dataD
Inputs: table (required).
!export-dbD
Inputs: table (required).
!firestoreD
Inputs: connection (required).
!functionsD
Inputs: no named parameters.
!mysqlD
Inputs: connection (required).
!pgD
Inputs: connection (required).
!queryD
Inputs: query (required).
!tablesD
Inputs: no named parameters.
!triggersD
Inputs: no named parameters.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
TDQS
Scored across 9 tools
The tools are completely indistinguishable due to the lack of descriptions and ambiguous naming. For example, '!export-data' and '!export-db' likely overlap significantly, while '!mysql' and '!pg' might both handle database operations without clear differentiation. Without descriptions, an agent cannot determine the purpose or boundaries of any tool.
The naming is inconsistent with a mix of conventions: some tools use hyphens (e.g., '!export-data'), others are single words (e.g., '!mysql'), and some are abbreviations (e.g., '!pg'). While all start with '!', there is no predictable verb_noun pattern or consistent style, making it hard to infer relationships.
With 9 tools, the count is reasonable for a database-related server, but the lack of descriptions makes it impossible to assess if this number is well-scoped. It could be appropriate if each tool covers a distinct aspect, but currently, it feels borderline due to the ambiguity.
The server appears to target database operations, but without descriptions, it is impossible to assess coverage. Tools like '!query' and '!tables' suggest basic operations, but there are likely significant gaps (e.g., no clear create, update, or delete tools) and no way to determine if the surface supports a complete workflow.
Maintenance
Related MCP Connectors
PostgreSQL, MySQL, and SQL Server in one session. 26 read-only MCP tools for AI agents.
Managed Postgres MCP: projects, SQL, docs search, and storage buckets via OAuth.
Hosted PostgreSQL MCP server for Claude, ChatGPT and Cursor, with each action switched per account.
The AI that understands raw data: Schema over your tables and databases, as MCP tools.
Related MCP Servers
- AlicenseBqualityDmaintenanceA Model Context Protocol server that enables powerful PostgreSQL database management capabilities including analysis, schema management, data migration, and monitoring through natural language interactions.185,295 npm204AGPL 3.0
- FlicenseNot gradedqualityDmaintenanceA Model Context Protocol server that provides tools for connecting to and interacting with various database systems (SQLite, PostgreSQL, MySQL/MariaDB, SQL Server) through a unified interface.3-
- -licenseNot gradedqualityNot gradedmaintenanceA Model Context Protocol server that provides tools for interacting with databases, including PostgreSQL, DuckDB, and Google Cloud Storage Parquet files.2-
- AlicenseNot gradedqualityDmaintenanceA Model Context Protocol server for interacting with MSSQL and PostgreSQL databases, offering tools for schema exploration and SQL execution. It features configurable query modes for safety and supports advanced authentication methods like Windows Auth and SSL.8 npmMIT