MCP SQL Server
Click on "Install 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., "@MCP SQL Servercalculate OEE for production line 1"
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.
MCP SQL Server
A Model Context Protocol (MCP) server that exposes a SQL Server database as tools for AI assistants like Claude, Gemini, and Copilot.
Features
test_connection— Verify database connectivitylist_tables— List all tables in the databasequery_sql— Execute arbitrary SQL queries (read/write with 100-row limit)get_oee_by_line— Calculate OEE metrics (Availability, Performance, Quality) for a production lineget_downtime_analysis— Aggregate downtime reasons sorted by durationget_shift_performance— KPI analytics for a specific shift and dateget_live_kpi— Fetch the latest OEE value from the live table
Related MCP server: MSSQL MCP Server
Prerequisites
Python 3.10+
Microsoft ODBC Driver 17+ for SQL Server
Access to a SQL Server database
Installation
# Clone the repository
git clone https://github.com/gigimento/mcp-sql-server.git
cd mcp-sql-server
# Create virtual environment
python -m venv .venv
.venv\Scripts\activate # Windows
# source .venv/bin/activate # Linux/macOS
# Install dependencies
pip install -r requirements.txtConfiguration
Copy .env.example to .env and adjust:
DB_SERVER=localhost\SQLEXPRESS
DB_NAME=YourDatabase
DB_DRIVER=ODBC Driver 17 for SQL Server
DB_TRUSTED_CONNECTION=yesOr set the corresponding environment variables directly.
Usage
With Claude Desktop / OpenCode
Add to your MCP config:
{
"mcpServers": {
"sql-server": {
"command": "python",
"args": ["path/to/server.py"],
"env": {
"DB_SERVER": "localhost\\SQLEXPRESS",
"DB_NAME": "YourDatabase"
}
}
}
}Standalone
python server.pyThe server communicates over stdio using the MCP protocol.
Expected Database Schema
The OEE tools expect tables similar to:
ProductionData— columns:Line,Date,Shift,Runtime,PlannedTime,GoodQty,RejectQty,TotalQty,PlannedQtyDowntime— columns:Line,Date,DowntimeReason,DurationOEE_Live— columns:Line,OEE,Timestamp
You can adapt the queries to match your schema by editing the tool functions in server.py.
License
MIT
This server cannot be installed
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Related MCP Servers
- AlicenseAqualityCmaintenanceEnables AI assistants to interact with Microsoft SQL Server databases through query execution, schema discovery, CRUD operations, stored procedures, and data export with built-in safety controls.Last updated28Apache 2.0
- Alicense-qualityFmaintenanceEnables AI assistants to interact with Microsoft SQL Server databases through a standardized interface. Supports executing SQL queries, browsing database schemas, and viewing table data with flexible authentication options for both local and Azure SQL databases.Last updated5MIT
- AlicenseAqualityDmaintenanceEnables AI models to interact with MS SQL Server databases through a standardized interface. Supports executing SQL queries with parameters, listing tables, and describing table schemas.Last updated3231MIT
- Alicense-qualityCmaintenanceEnables AI assistants to interact with Microsoft SQL Server databases via introspection and query tools. Supports single or multiple databases with read-only mode by default and an optional write capability.Last updated5054MIT
Related MCP Connectors
Connect your AI assistants to Keboola and expose your data, transformations, SQL queries, ...
Gateway between LLM agents and world data through eight tools and a bundled endpoint catalog.
Provide real-time data querying and visualization by integrating Tako with your agents. Generate o…
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
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/gigimento/mcp-sql-server'
If you have feedback or need assistance with the MCP directory API, please join our Discord server