@@ -14,7 +14,6 @@ This project is a .NET 8 console application implementing a Model Context Protoc
1414 - InsertData: Insert data into tables.
1515 - ReadData: Read/query data from tables.
1616 - UpdateData: Update values in tables.
17- - SearchData: Perform vector or full-text search on table columns.
1817- ** Logging** : Console logging using Microsoft.Extensions.Logging.
1918- ** Unit Tests** : xUnit-based unit tests for all major components.
2019
@@ -50,6 +49,8 @@ This project is a .NET 8 console application implementing a Model Context Protoc
5049```
5150---
5251
52+ NOTE: Replace the path "C:\\ src\\ SQL-AI-samples" with the location of your SQL-AI-samples repo on your machine.
53+
5354e.g. your MCP settings should look like this if "MSSQL MCP" is your own MCP Server in VSCode settings:
5455
5556---
@@ -59,7 +60,7 @@ e.g. your MCP settings should look like this if "MSSQL MCP" is your own MCP Serv
5960 "servers" : {
6061 "MSSQL MCP" : {
6162 "type" : " stdio" ,
62- "command" : " C:\\ src\\ MssqlMcp\\ bin\\ Debug\\ net8.0\\ MssqlMcp.exe" ,
63+ "command" : " C:\\ src\\ SQL-AI-samples \\ MssqlMcp \\ MssqlMcp\\ bin\\ Debug\\ net8.0\\ MssqlMcp.exe" ,
6364 "env" : {
6465 "CONNECTION_STRING" : " Server=.;Database=test;Trusted_Connection=True;TrustServerCertificate=True"
6566 }
@@ -68,6 +69,23 @@ e.g. your MCP settings should look like this if "MSSQL MCP" is your own MCP Serv
6869```
6970---
7071
72+ And example of using a connection string for Azure SQL Database:
73+ ---
74+ ```json
75+ "mcp" : {
76+
77+ "servers" : {
78+ "MSSQL MCP" : {
79+ "type" : " stdio" ,
80+ "command" : " C:\\ src\\ SQL-AI-samples\\ MssqlMcp\\ MssqlMcp\\ bin\\ Debug\\ net8.0\\ MssqlMcp.exe" ,
81+ "env" : {
82+ "CONNECTION_STRING" : " Server=tcp:<servername>.database.windows.net,1433;Initial Catalog=<databasename>;Encrypt=Mandatory;TrustServerCertificate=False;Connection Timeout=30;Authentication=Active Directory Interactive"
83+ }
84+ }
85+ }
86+ ```
87+ ---
88+
7189**Run the MCP Server**
7290
7391Save the Settings file, and then you should see the "Start" button appear in the Settings json. Click "start" to start the MCP Server.
@@ -90,7 +108,7 @@ Add a new MCP Server with the following settings:
90108{
91109 "mcpServers" : {
92110 "MSSQL MCP" : {
93- "command" : " C:\\ src\\ MssqlMcp\\ MssqlMcp\\ bin\\ Debug\\ net8.0\\ MssqlMcp.exe" ,
111+ "command" : " C:\\ src\\ SQL-AI-samples \\ MssqlMcp\\ MssqlMcp\\ bin\\ Debug\\ net8.0\\ MssqlMcp.exe" ,
94112 "env" : {
95113 "CONNECTION_STRING" : " Server=.;Database=test;Trusted_Connection=True;TrustServerCertificate=True"
96114 }
@@ -101,5 +119,9 @@ Add a new MCP Server with the following settings:
101119
102120Save the file, start a new Chat, you'll see the "Tools" icon, it should list 8 MSSQL MCP tools.
103121
122+ # Troubleshooting
123+
124+ 1 . If you get a connection reset error using "Active Directory Default", try "Active Directory Interactive"
125+
104126
105127
0 commit comments