SQL Server MCP Servers in 2026: 7 Options Compared

Seven ways to give AI agents MCP access to Microsoft SQL Server, compared on auth, read-only control, permission granularity, raw T-SQL, stored procedures, maturity, licensing and hosting. Checked against each project's docs, repository and pricing page on October 16, 2026.

Key takeaways

  • Azure and Entra ID shops: Microsoft's SQL MCP Server, part of Data API builder (DAB), is the default choice. It is MIT-licensed, has no NL2SQL by design, and supports per-entity, per-field and row-level policies. It needs SQL Server 2016 or later, and HTTP roles only activate once you configure an identity provider.
  • Microsoft's MSSQL MCP Server sample is gone. Microsoft removed it from Azure-Samples on June 3, 2026, in a pull request titled "Removed unsafe MCP sample". Tutorials that still link to it point to a dead folder.
  • DBHub is the lightest way to explore SQL Server from Claude Code or Cursor. HTTP auth is off unless you set --auth-token. SQL Server has no native read-only transaction, so DBHub's read-only mode uses a keyword check plus a transaction it always rolls back.
  • On-prem SQL Server that needs REST and MCP with per-table roles: Faucet fits, with a built-in TDS driver and no ODBC install. Access uses API keys and table-level roles rather than Entra ID and row-level policies. See the SQL Server REST API guide.
  • Hosted or commercial options: CData Connect AI (hosted subscription, free Developer Edition with limits, on-prem reach through its Connect Gateway) and DreamFactory (self-hosted, SQL Server on paid plans).

Seven ways to put an MCP server in front of Microsoft SQL Server, compared on auth, read-only control, permissions and licensing. Competitor details come from each project’s docs, repository and pricing page, checked October 16, 2026; Faucet’s come from its source code. We did not run these servers against SQL Server for this post.

What is the best SQL Server MCP server?

The best SQL Server MCP server depends on your setup. Microsoft’s SQL MCP Server, part of Data API builder, is best for Azure and Entra ID shops on SQL Server 2016 or later. DBHub is best for developers exploring a database from Claude Code or Cursor. MCP Toolbox for Databases is best for curated, parameterized T-SQL tools. Faucet is best for on-prem SQL Server that needs REST and MCP under per-table roles. The community mssql_mcp_server is best for quick local stdio use, DreamFactory for a commercially supported platform, and CData Connect AI for a hosted, multi-source endpoint.

SQL Server MCP servers compared at a glance

SQL Server MCP servers compared, verified from docs and source on October 16, 2026. Listed by use case, not ranked. Faucet is our product.

ToolBest forMaturityAuth on HTTPAccess controlRaw T-SQL toolProcedures as MCP toolsAudit / observabilityLicense / pricing modelSelf-hosted
SQL MCP Server (DAB)Azure / Entra shops, SQL Server 2016+v2.1.5 (Oct 1, 2026), MicrosoftEntra ID, custom JWT, App Service EasyAuth; default “Unauthenticated” provider runs everything as anonymousPer entity and action, field include/exclude, row-level database policiesNo, by designYes (DAB 2.0+)OpenTelemetry per tool call, Application InsightsMIT, freeYes (container, any cloud, on-prem)
DBHubLocal dev explorationv1.5.0 (Oct 9, 2026), ~3.7k starsOff by default; optional static bearer tokens (--auth-token)Per-tool readonly, max_rows, custom toolsYes (execute_sql)Via EXEC onlyRequest traces in its workbenchMIT, freeYes (npx, Docker)
MCP Toolbox for DatabasesCurated T-SQL tools, Google Cloudv1.14.0 (Oct 8, 2026), GoogleGeneric OIDC for the whole endpoint, or per-tool auth servicesWhatever tools you define in tools.yamlYes in the prebuilt config; optional in custom configsVia EXEC onlyOpenTelemetry traces and metricsApache-2.0, freeYes
FaucetOn-prem SQL Server, REST + MCPv0.1.15 (Oct 9, 2026), pre-1.0, 138 starsAPI keys (X-API-Key)Roles per database, table and HTTP verb; read-only database flagOff by default; needs raw SQL enabled on a writable database plus all verbs on _sqlNo (REST only)Structured request logs with request IDsMIT, freeYes (single binary, Docker)
mssql_mcp_server (community)Quick local stdio, Windows auth0.1.0 (Jun 2025), ~400 stars, last commit Nov 2025Not applicable (stdio)None in the server; relies on the loginYes, including INSERT/UPDATE/DELETEVia EXEC onlyNoneMIT, freeYes (uvx, pip)
DreamFactoryCommercially supported API platformCommercial vendorOAuth 2.0 for AI clients; optional API key for headless clientsRole-based, per serviceNot documented as an MCP toolYesNot checked for this postApache-2.0 core (PostgreSQL only); SQL Server on paid plansYes
CData Connect AIHosted multi-source MCPCommercial SaaSOAuth, or Basic with user ID and personal access tokenPasses through SQL Server permissionsSELECT-only queryData; separate insert and update toolsYes (executeProcedure)Query logging, per CDataProprietary SaaS; per-plan subscription with add-ons; 14-day trial; free Developer Edition with limitsNo (hosted; on-prem gateway)

How we evaluated

We compared each tool on HTTP authentication, how read-only is enforced, permission granularity (database, table, column, row), arbitrary T-SQL, stored procedures, SQL Server connection options (named instances, Windows or Entra auth), maturity, observability, license and hosting.

What this is based on. Each project’s own documentation, GitHub repository and pricing page, checked on October 16, 2026. Release numbers and star counts come from the GitHub API on the same day. We did not run any of these servers against SQL Server for this post, so nothing below says “tested”. Faucet’s details come from its source code at v0.1.15. We checked the Faucet role example below against a local Faucet build on SQLite, not SQL Server. Where docs are silent, we say so.

What is a SQL Server MCP server?

An MCP server exposes tools to an AI client over stdio or Streamable HTTP. A SQL Server MCP server holds the connection string and turns tool calls into T-SQL. The key question is how much T-SQL the model writes: all of it (raw-SQL tools), none (structured CRUD tools) or only parameter values (curated queries). For app-to-app calls with fixed contracts, REST is still the better fit.

1. SQL MCP Server (Microsoft Data API builder): Best for Azure and Entra ID shops

Best for: teams on SQL Server 2016+, Azure SQL or SQL database in Fabric that want a Microsoft-backed, role-aware MCP endpoint and can live with configuring entities explicitly.

SQL MCP Server is not a separate product. It is the MCP endpoint of Data API builder, Microsoft’s MIT-licensed engine that serves REST and GraphQL from a JSON config. It arrived in DAB 1.7, and the current release is v2.1.5 (October 1, 2026). One dab-config.json drives all three surfaces, so the permissions you write for REST also apply to agents. We covered the architecture when it launched in Microsoft’s DAB MCP server and the unified data API.

dab init --database-type mssql --connection-string "@env('SQL_CONN')" --host-mode development
dab add Orders --source dbo.Orders --permissions "reader:read" --description "Customer orders"
dab start --mcp-stdio role:reader   # local stdio, evaluated as the reader role

Over HTTP (dab start, MCP at /mcp), the reader role never activates under DAB 2.0’s default Unauthenticated provider, which runs every request as anonymous. Configure EntraId, Custom or AppService with dab configure first, or grant anonymous:read behind a trusted front end.

Strengths

  • No NL2SQL. Agents get seven DML tools: describe_entities, create_record, read_records, update_record, delete_record, execute_entity and aggregate_records. DAB’s query builder writes the T-SQL, not the model.
  • The finest-grained permissions in this list. Rules can be set per entity and action, with field include/exclude lists. Row-level database policies, such as @item.ownerId eq @claims.userId, apply to read, update and delete (the authorization overview excludes create; the feature table lists it). Claims can be passed into SESSION_CONTEXT for SQL Server row-level security.
  • Identity. It supports Microsoft Entra ID, custom JWT providers (Okta, Auth0, Keycloak) and App Service EasyAuth. On-Behalf-Of flow is supported for SQL Server. It can use managed identities to reach the database.
  • Stored procedures as named tools with "custom-tool": true (DAB 2.0+).
  • Operations features include OpenTelemetry traces per tool call, health checks, Application Insights, L1/L2 caching of read_records, and Azure Key Vault references in config.

Things to know

  • Minimum SQL Server 2016, per Microsoft’s feature-availability table. Older instances are out.
  • Unsupported SQL Server types include geography, geometry, hierarchyid, json, rowversion, sql_variant, vector and xml.
  • No API-key security. The feature table lists it as unsupported.
  • No DDL (by design) and no ad hoc queries. If an agent needs a join you haven’t modeled, you add a view or relationship to the config.
  • Stdio mode uses the Simulator auth provider with a role you name on the command line. That’s fine for local work, but it isn’t identity.

Who should choose it

Choose it if you are a Microsoft shop on a supported SQL Server version and already use Entra ID. You get the strongest policy model here and a vendor behind it.

2. DBHub (Bytebase): Best for developers exploring SQL Server locally

Best for: a developer or DBA who wants Claude Code, Cursor or VS Code to browse schemas and run queries against a dev or staging SQL Server in a few minutes.

DBHub is an MIT-licensed TypeScript MCP server from Bytebase (v1.5.0, October 9, 2026). It covers PostgreSQL, MySQL, MariaDB, SQL Server, Oracle and SQLite. Its default tool surface is deliberately small: execute_sql and search_objects, with explain_sql, health_check and custom parameterized tools as opt-ins. That small surface matters because of the context window cost of large MCP tool lists.

[[sources]]
id = "corp_sqlserver"
type = "sqlserver"
host = "sqlserver.corp.local"
database = "app_db"
user = "jsmith"
password = "secret"
authentication = "ntlm"
domain = "CORP"

[[tools]]
name = "execute_sql"
source = "corp_sqlserver"
readonly = true
max_rows = 1000

Strengths

  • Good SQL Server connection coverage: named instances (instanceName), NTLM with a domain, and Azure AD access tokens, plus SSH tunnels and TLS.
  • Per-tool guardrails. readonly and max_rows (with a truncated flag) are set per tool in [[tools]]; connection and query timeouts per source in [[sources]].
  • A read-only backstop on SQL Server. SQL Server has no native read-only transaction, so DBHub checks statements against a keyword allow-list, blocks escape constructs, and runs read-only queries in a transaction it always rolls back.
  • Quick setup. It runs with npx, Docker, an MCP Bundle (read-only) or a Claude Code plugin, and includes a browser workbench with request traces.

Things to know

  • HTTP auth is off unless you set it. --auth-token adds static bearer tokens. The server binds to 0.0.0.0 by default, and the docs warn you to bind to 127.0.0.1 or front it with a proxy.
  • Read-only on SQL Server is enforced by DBHub, not the engine. The docs list engine-level enforcement for PostgreSQL, MySQL/MariaDB and SQLite only, and say to “always connect DBHub with a least-privilege, read-only database user.”
  • No per-table roles or identity. Everyone holding the token gets the same tools.
  • Requires Node.js 22.5 or later.

Who should choose it

Choose it for individual developer workflows on dev or staging databases. For shared or production access, use a SELECT-only login or a server with roles.

3. MCP Toolbox for Databases (Google): Best for curated T-SQL tools

Best for: teams that want to hand an agent a fixed set of named, parameterized queries rather than open-ended SQL, and teams already on Google Cloud SQL for SQL Server.

MCP Toolbox for Databases (repo googleapis/mcp-toolbox, formerly genai-toolbox) is an Apache-2.0 Go server, at v1.14.0 (October 8, 2026). It has two SQL Server integrations: self-hosted SQL Server (type: mssql) and Cloud SQL for SQL Server. You describe sources, tools and toolsets in tools.yaml. An mssql-sql tool binds a single T-SQL statement with typed parameters, so the model fills in values but cannot change the query.

kind: source
name: erp
type: mssql
host: 10.0.0.12
port: 1433
database: erp
user: ${MSSQL_USER}
password: ${MSSQL_PASSWORD}

Strengths

  • Curated tools are a strong guardrail. Each tool is one statement you reviewed. Toolsets let a client load only the tools it needs (/mcp/{toolset}).
  • Broad source coverage if SQL Server is one of many databases.
  • Endpoint and tool auth. Generic OIDC can protect the whole MCP endpoint (mcpEnabled: true) with standard bearer tokens. Otherwise, auth services (Google Sign-In, generic OIDC) apply per tool through authenticated parameters and authorized invocations.

Things to know

  • The prebuilt SQL Server config is open-ended. --prebuilt mssql exposes execute_sql and list_tables. Toolbox’s read-only mode (readOnly source flag, *_READONLY variables) doesn’t list SQL Server in its enforcement matrix, and the prebuilt mssql page gives no read-only guidance. Permissions come down to the login.
  • SQL logins only for self-hosted SQL Server. The source page says it “only uses standard authentication.” There is no Windows or Entra option.
  • Curated tools take work. Every query an agent might need has to be written into tools.yaml first.

Who should choose it

Choose it if you want the agent limited to reviewed queries, or if your SQL Server runs on Cloud SQL. It is less natural for an Entra-centric shop.

4. Faucet: Best for on-prem SQL Server needing REST and MCP

Best for: teams with SQL Server behind a firewall that need one service to give apps a REST API and agents an MCP endpoint, under the same per-table roles, without installing an ODBC driver.

Faucet, the open-source database-to-REST-API and MCP server, is a single MIT-licensed Go binary (v0.1.15, October 9, 2026; 138 GitHub stars). It connects to SQL Server over TDS with the pure-Go go-mssqldb driver, introspects the dbo schema (or another you choose), and serves REST, an OpenAPI 3.1 spec and MCP at /mcp on one port. The SQL Server REST API and MCP guide walks through setup, and the SQL Server tutorial in the docs covers schemas, stored procedures and Docker.

faucet db add --name erp --driver mssql \
  --host sql01.internal --user api_reader --password-prompt --database erp
# self-signed certificate? add: --param TrustServerCertificate=true
faucet role create --name agent-reader --service erp --component Orders --verbs GET
faucet role grant  --role agent-reader --service erp --component Customers --verbs GET
faucet role grant  --role agent-reader --service erp --component _table --verbs GET  # table listing
faucet key create --role agent-reader --label claude    # prints the key once
faucet serve

claude mcp add --transport http faucet http://localhost:8080/mcp \
  --header "X-API-Key: faucet_YOUR_KEY"

A bare table name such as Orders covers both the data (_table/Orders) and its schema (_schema/Orders). A rule on _table/Orders alone lets the agent query but not describe the table.

Strengths

  • Older SQL Server versions are likely to work. Paging uses OFFSET/FETCH, introduced in SQL Server 2012, so 2012 is the floor in theory. Faucet’s docs list support through 2022. Neither range was tested for this post, and SQL Server 2012 and 2014 are past Microsoft’s extended support.
  • No client driver to install. No ODBC or Native Client on the host.
  • One role model for REST and MCP. Rules match a database, a component pattern (Orders, _table/cust*) and HTTP verbs, and each MCP tool call is checked like the matching HTTP request, failing closed. A read-only database flag blocks writes on both surfaces whatever a role allows. The RBAC docs cover the rule syntax.
  • Narrow agent surface. The MCP server has eight tools: list services, list tables, describe table, query, insert, update, delete, and a raw SQL tool. Raw SQL runs only when the database has it enabled (admin UI or API), is not read-only, and the role grants all five verbs on _sql. Updates and deletes require a filter.
  • Some SQL Server specifics. The MCP insert tool wraps explicit identity values in SET IDENTITY_INSERT (REST does not). Stored procedures are listed at GET /_proc and called with POST /_proc/{name}.

Things to know

  • API keys and SQL authentication. Agents authenticate with API keys, and Faucet connects to SQL Server with SQL authentication, so Azure SQL servers set to Entra-only auth aren’t a fit.
  • Table-level roles. Rules apply per database, table and verb rather than per row or column.
  • Procedures over REST. Stored procedures are called at POST /_proc/{name}; there is no procedure MCP tool.
  • Young project. Faucet is pre-1.0, with about 138 GitHub stars.

Who should choose it

Choose it if your SQL Server is on-prem, you want apps and agents on one governed API, and table-level roles with API keys meet your security bar. If you need Entra identity or row-level policies, DAB is the better fit.

5. mssql_mcp_server (community, not Microsoft): Best for a quick local stdio connection

Best for: a single developer who wants Claude Desktop to query a local or LocalDB SQL Server with Windows authentication, and accepts that it can write.

Despite its PyPI name, RichardHan/mssql_mcp_server is a community project. It’s an MIT-licensed Python server (PyPI microsoft_sql_server_mcp 0.1.0, June 2025; about 400 stars; last commit November 2025) built on pymssql. It runs over stdio and exposes tables as resources plus one SQL tool. We picked it because it is the most-starred community SQL Server MCP server.

Strengths

  • One-line setup with uvx microsoft_sql_server_mcp and environment variables.
  • SQL and Windows authentication, LocalDB and custom ports. Azure SQL works through a SQL login: the README lists “Azure AD”, but its example uses only SQL credentials.

Things to know

  • No read-only mode. Non-SELECT statements (INSERT, UPDATE, DELETE) are run and committed, so the login’s permissions are the only guardrail.
  • Stdio only. There is no HTTP transport, auth or roles.
  • Fixes on main aren’t released. The only PyPI release is 0.1.0, so uvx installs June 2025 code without later encryption and comment-stripping fixes.

Also considered: Aaronontheweb/mssql-mcp (.NET, Apache-2.0, about 160 stars, last push January 2026), aadversteeg/mssqlclient-mcp-server (MIT, last push October 2026) and JexinSam/mssql_mcp_server (MIT, last push August 2026).

Who should choose it

Choose it for throwaway local experiments only. Point it at a login that can do nothing you’d regret.

6. DreamFactory: Best for a commercially supported API platform

Best for: enterprises that want vendor support, many connectors, and an MCP server with OAuth on top of SQL Server and other sources.

DreamFactory’s platform generates REST APIs for databases and file stores, and its MCP Server service exposes them to agents. One endpoint covers several services, with tools prefixed per API: schema discovery, CRUD, aggregates, and stored procedures and functions.

Strengths

  • OAuth 2.0 for AI clients such as VS Code, Claude and Cursor. Tools are filtered to the services the user’s role allows. Headless clients can use an API key header if the service opts in.
  • Stored procedures and functions are first-class MCP tools.
  • Commercial support and connectors well beyond SQL Server.

Things to know

  • SQL Server is not in the free edition. The open-source edition includes only PostgreSQL. SQL Server comes with paid plans: DF Linux Lite, listed as covering all connectors except Oracle, Snowflake and DB2, starts at $1,500 per month billed annually.
  • Heavier platform. It is a larger system to deploy than a single-purpose MCP server.

Who should choose it

Choose it if you want vendor support, OAuth for AI clients and stored procedures as first-class MCP tools, and a commercial SQL Server plan fits your budget.

7. CData Connect AI: Best for a hosted, multi-source MCP endpoint

Best for: analysts and teams that want one hosted MCP endpoint over SQL Server plus SaaS systems, without running a server.

CData Connect AI is a proprietary, fully hosted service. You add SQL Server as a source and point your AI client at Connect AI’s remote MCP endpoint. Its MCP tools cover catalog and schema discovery, a queryData tool that “accepts only SELECT statements”, separate execute_insert and execute_update tools, and getProcedures and executeProcedure. CData says it uses your SQL Server permissions and logs queries.

Strengths

  • Nothing to host, and the same endpoint reaches many other systems.
  • On-prem reach without inbound ports. Connect Gateway, a Docker or Helm component you run on your network, opens a reverse tunnel to Connect AI. SQL Server is on its supported list.
  • Governance on higher tiers. Passthrough identity, SCIM and enterprise SSO are listed on the Business plan.

Things to know

  • Subscription pricing per plan (Standard, Growth, Business), with add-ons per user and per source, and a fair-use cap on records per month. There is a 14-day trial and a free Developer Edition (5 users, 5 sources, 500 tool calls a month); that page doesn’t say whether SQL Server is included.
  • Your query traffic goes through a third party, which some data policies rule out.

Who should choose it

Choose it if you would rather not run any infrastructure, SQL Server is one of several sources your agents need, and your data policy allows queries to pass through a third-party service. Check the record cap and gateway setup first.

SQL MCP Server vs the MSSQL MCP Server: which Microsoft option?

Use SQL MCP Server. Many 2025 tutorials point to the MSSQL MCP Server, a preview sample in Azure-Samples/SQL-AI-samples with .NET and Node versions and Entra ID sign-in. On June 3, 2026, Microsoft merged a pull request titled “Removed unsafe MCP sample”. Its description says the demo “has been scrubbed from our blogs” and kept “leading [customers] down the wrong road for developing MCP solutions.” The folder no longer exists, and the original devblog post now returns 404.

The difference is architectural. Per contemporary coverage, the preview sample let the model create and drop tables, write data and create indexes. SQL MCP Server exposes only entities you configured, under roles and policies you defined.

Two other Microsoft projects come up in searches. The Azure MCP Server (microsoft/mcp, release 3.0.0 on October 12, 2026) has Azure SQL tools that manage resources: create or update databases, list elastic pools, manage firewall rules and list Entra admins. They don’t query your data. The MSSQL extension for VS Code adds Agent Mode tools for GitHub Copilot, such as listing tables and running queries, inside the editor.

DBHub vs MCP Toolbox for SQL Server

Both are free, multi-database and self-hosted. They differ in who writes the SQL. DBHub assumes the agent writes it, and has better SQL Server connection options (named instances, NTLM, Azure AD tokens). MCP Toolbox is strongest when you write it as reviewed, parameterized mssql-sql tools. For exploring a dev database, DBHub is quicker. For a production agent limited to known queries, a curated Toolbox config gives tighter control.

How to choose a SQL Server MCP server

Read-only access to SQL Server

SQL Server has no read-only transaction mode, so servers that offer read-only enforce it in their own layer: DAB through read-only entity permissions, Faucet through GET-only roles or a read-only database, DBHub through a rollback-only transaction. Back each one with a SELECT-only login. Our guide to giving an AI agent read-only database access walks through both layers.

On-prem SQL Server vs Azure SQL

On-prem, run a self-hosted server next to the database, or use CData’s gateway. Azure SQL with Entra-only auth rules out Faucet and Toolbox’s self-hosted source.

Entra ID and Windows authentication

DAB supports Entra ID both for agents and for its own connection to the database. DBHub supports NTLM and Azure AD tokens to the database, and the community server supports Windows auth.

Stored procedures

If procedures are your API, DAB, DreamFactory and CData expose them as MCP tools. Faucet exposes them over REST only.

A baseline for any server

  • Give it a dedicated SQL Server login with only the permissions the agent needs.
  • Keep port 1433 private and expose only the MCP endpoint, over HTTPS.
  • Require authentication on that endpoint.

If your SQL Server is on-prem and you want apps and agents on one governed API, try Faucet. The SQL Server REST API guide gets you from connection to a role-scoped MCP endpoint, turning a database into a REST API and MCP server covers the general setup, and connecting Claude to your database shows the client side. If you’re on Azure with Entra ID, start with Data API builder.

Frequently asked questions

Does Microsoft have an official SQL Server MCP server?

Yes. SQL MCP Server is part of Data API builder 1.7 and later. It is open source (MIT), self-hosted, and exposes tables, views and stored procedures you configure as seven DML tools over Streamable HTTP or stdio. Microsoft's earlier MSSQL MCP Server sample was removed from the Azure-Samples repository in June 2026. The Azure MCP Server has Azure SQL management tools, not data queries.

What is the difference between SQL MCP Server and the MSSQL MCP Server?

SQL MCP Server is a supported feature of Data API builder. Agents work through configured entities, roles and policies, and it never generates free-form T-SQL. The MSSQL MCP Server was a 2025 preview sample in Azure-Samples, with Entra ID sign-in and table-level tools. Microsoft removed it on June 3, 2026, calling it unsafe. For new projects, use SQL MCP Server.

Can I connect an AI agent to an on-premises SQL Server without exposing port 1433?

Yes. Run the MCP server on a host inside your network next to SQL Server, and expose only its HTTPS endpoint through a reverse proxy or tunnel. Data API builder, Faucet, DBHub and MCP Toolbox all run self-hosted this way. CData Connect AI uses its Connect Gateway, a reverse tunnel you install on-prem. The agent never gets a connection string.

How do I give an AI agent read-only access to SQL Server?

Use two layers. In SQL Server, create a login and user with SELECT only on the schemas the agent needs. In the MCP server, use its own read-only control: read-only entity permissions in Data API builder, a GET-only role or read-only database in Faucet, or readonly = true on a DBHub tool. Avoid servers that run any T-SQL under a privileged login.

Do SQL Server MCP servers support stored procedures?

Some do. Data API builder can register a stored procedure as a named MCP tool (DAB 2.0 and later). DreamFactory's MCP server lists and calls procedures, and CData Connect AI has an executeProcedure tool. Faucet calls procedures over REST with POST /_proc/{name} rather than through an MCP tool. Raw-SQL servers can run EXEC with no per-procedure restriction.

Is it safe to let an AI agent run raw T-SQL?

Only with a least-privilege login. A raw-SQL tool lets the model write any statement the login is allowed to run. Keyword filters and rollback-only transactions help, but DBHub's own docs still tell you to connect with a read-only database user. Structured tools such as DAB's DML tools or Faucet's query tool narrow what an agent can ask for.

Sources

Last reviewed