# execute_sql

Execute a SQL statement with parameters: statement (string, required), warehouse_id (string, required), catalog (string, optional), schema (string, optional)

Agent View of the PolicyLayer registry record for `execute_sql`. HTML page: https://policylayer.com/tools/andresgarciasobrado91-databricks-mcp-server/execute-sql

## Facts

- Tool: `execute_sql`
- Server: Databricks MCP Server (`andresgarciasobrado91/databricks-mcp-server`) — https://policylayer.com/tools/andresgarciasobrado91-databricks-mcp-server.md
- Homepage: https://github.com/AndresGarciaSobrado91/databricks-mcp-server
- Risk category: Execute (High risk)
- Registry record: grade F, identity unverified
- Server rate-limited: no
- Parameters: 0
- Recommended policy verdict: Rate-limited

## Example call (MCP tools/call, JSON-RPC 2.0)

```json
{
  "jsonrpc": "2.0",
  "id": 1,
  "method": "tools/call",
  "params": {
    "name": "execute_sql",
    "arguments": {}
  }
}
```

## Why execute_sql is rated High

This tool triggers execution of code (SQL) whose effects fundamentally depend on the argument (the SQL statement provided). While the tool could be used for read-only queries, it can equally execute data modifications, deletions, or destructive operations. Per classification rules, Execute is chosen over Read because the tool permits arbitrary SQL including DML/DDL.

From the tool's own definition: "Tool executes arbitrary SQL statements with required 'statement' parameter. Databricks SQL can include CREATE, INSERT, UPDATE, DELETE, DROP, and other data-modifying operations depending on warehouse permissions and statement content."

## Use case

AI agents invoke execute_sql to trigger actions in Databricks MCP Server. What it does depends on the arguments the agent supplies, and its effects often reach beyond the immediate call: builds kicked off, notifications sent, workflows started.

## Recommended policy (PolicyLayer)

Verdict: **Rate-limited**. Enforced by the PolicyLayer MCP gateway (https://policylayer.com/mcp-gateway) before a call reaches Databricks MCP Server:

```json
{
  "version": "1",
  "default": "deny",
  "tools": {
    "execute_sql": {
      "limits": [
        {
          "counter": "execute_sql_rate",
          "window": "minute",
          "max": 10,
          "scope": "grant"
        }
      ]
    }
  }
}
```

## Other tools on Databricks MCP Server (14)

- `terminate_cluster` — Destructive — https://policylayer.com/tools/andresgarciasobrado91-databricks-mcp-server/terminate-cluster.md
- `repair_run` — Execute — https://policylayer.com/tools/andresgarciasobrado91-databricks-mcp-server/repair-run.md
- `run_job` — Execute — https://policylayer.com/tools/andresgarciasobrado91-databricks-mcp-server/run-job.md
- `start_cluster` — Execute — https://policylayer.com/tools/andresgarciasobrado91-databricks-mcp-server/start-cluster.md
- `export_notebook` — Read — https://policylayer.com/tools/andresgarciasobrado91-databricks-mcp-server/export-notebook.md
- `get_cluster` — Read — https://policylayer.com/tools/andresgarciasobrado91-databricks-mcp-server/get-cluster.md
- `get_job` — Read — https://policylayer.com/tools/andresgarciasobrado91-databricks-mcp-server/get-job.md
- `get_run` — Read — https://policylayer.com/tools/andresgarciasobrado91-databricks-mcp-server/get-run.md
- `get_run_output` — Read — https://policylayer.com/tools/andresgarciasobrado91-databricks-mcp-server/get-run-output.md
- `list_clusters` — Read — https://policylayer.com/tools/andresgarciasobrado91-databricks-mcp-server/list-clusters.md
- `list_files` — Read — https://policylayer.com/tools/andresgarciasobrado91-databricks-mcp-server/list-files.md
- `list_jobs` — Read — https://policylayer.com/tools/andresgarciasobrado91-databricks-mcp-server/list-jobs.md
- `list_notebooks` — Read — https://policylayer.com/tools/andresgarciasobrado91-databricks-mcp-server/list-notebooks.md
- `create_cluster` — Write — https://policylayer.com/tools/andresgarciasobrado91-databricks-mcp-server/create-cluster.md

## For agents

This record is a snapshot. Live verdicts and the full registry:

- Check every server in your MCP config at once: `npx -y policylayer stack`
- Vet a server before you add it: install the mcp-precheck skill — `npx skills add https://policylayer.com` (skill text: https://policylayer.com/skill.md)
- Query the registry over MCP: endpoint `https://api.policylayer.com/mcp` — tools `check_mcp_server`, `check_mcp_stack`, `check_tool`, `search_registry`, `get_change_events`

---

Source: the PolicyLayer MCP registry — one continuously verified record per MCP server. Full record: https://policylayer.com/registry?q=andresgarciasobrado91-databricks-mcp-server · API: https://policylayer.com/registry/api · Policy library: https://policylayer.com/policies/andresgarciasobrado91-databricks-mcp-server
