Query Oracle Database with Claude or Cursor via MCP.
Connect Oracle Database — on-prem, RAC, Exadata, Autonomous, or 19c — to Claude or Cursor with one MCP key. Schema Intelligence handles PL/SQL dialects so the AI writes valid Oracle SQL on its first try, over a secure outbound-only cloud link with no port forwarding.
Ask Nova, get SQL + charts
Meet Nova Database REST APIOne key per partner. No credentials shared.
Build an API AutomationScheduled sync to 6+ platforms
Explore API to SQLQuery APIs with SQL, no code
Explore AI Database MCPClaude, Cursor, ChatGPT & Grok talk to your data
Connect AIQuery Streams is a secure, real-time data integration platform that brings every database and SaaS API in your account into Claude, Cursor, ChatGPT, and Grok — through a single MCP key with no firewall changes. This guide walks through wiring up the Oracle MCP connector specifically, so your AI tool can answer plain-English questions about employees, departments, orders, financials, and any other Oracle Database data — joins, aggregations, PL/SQL dialect-specific syntax, schema exploration, ad-hoc reporting — without you copy-pasting CSV exports out of SQL Developer, Toad, or SQL*Plus. Whether you’re running Oracle 19c on-prem, Oracle Autonomous Database in OCI, Oracle XE on a developer workstation, or a RAC cluster on Exadata, the Oracle MCP server connects them all to your AI client through one key. Learn more at QueryStreams.com and sign up for free to start asking your AI tool real Oracle questions.
What Query Streams MCP gives you for Oracle Database
Other “Oracle MCP” servers on the open-source landscape connect the AI tool directly to an Oracle TNS connection string. That works, but it pushes a database password (and often a wallet) into your AI client’s config, scopes the AI tool to only that one Oracle endpoint, and gives you no audit trail of what the AI actually asked. The Query Streams MCP server for Oracle solves a wider problem: one key, every connector, full audit trail, and the AI tool never holds your Oracle credentials.
Zero inbound firewall holes
The Network Agent opens a single outbound encrypted cloud link to Query Streams. Your AI client connects to the cloud, never to your Oracle host. No port to open, no IP to allowlist, no VPN, no Oracle TNS listener exposed to the public internet.
One key, every connector
The same MCP key reaches every database and SaaS API your account has connected. Add a Stripe or PostgreSQL connector tomorrow and the AI tool sees it next to your Oracle schemas without re-keying.
Schema Intelligence baked in
The AI sees AI-curated descriptions, semantic types, enum value lists, and confidence-scored foreign keys for every Oracle column — not just bare ALL_TAB_COLUMNS output. It writes accurate Oracle SQL on the first try, even on legacy schemas with the 30-character column-name truncations of pre-12c databases.
Read-only enforced at the agent
Even a hallucinating LLM can’t issue DELETE, UPDATE, or TRUNCATE through Query Streams MCP. The Network Agent rejects anything that isn’t SELECT, WITH, or EXPLAIN before Oracle ever sees the SQL.
Per-key rate limits
Default 60 requests per minute and 10 execute calls per minute, configurable per key. A runaway AI tool-call loop hits a token bucket, not your Oracle session limit or your Autonomous Database OCPU bill.
How it works without opening firewall ports
The Network Agent installs once on any host that can reach your Oracle Database over Oracle Net Services (TNS) and dials a single outbound TLS link to the cloud — nothing inbound is ever exposed, and the AI tool never sees your Oracle TNS connection string or wallet. how the outbound-only connection works →
AI Client
Cursor, Claude,
ChatGPT, Grok
QS MCP Server
Streamable HTTP
X-MCP-Key auth
Network Agent
On your network
Cloud link out
Oracle Database
TNS / wallet held
by the agent
The MCP key you give Cursor or Claude is scoped (read / analyze / execute), revocable at any time, and rate-limited per-key. The AI tool calls these MCP tools to do its work:
pattern_key with optional parameter overrides.Why Schema Intelligence makes Query Streams MCP different
Most “MCP for Oracle” servers in the open-source landscape hand your AI tool the same ALL_TAB_COLUMNS view Oracle hands a stranger. Column names. Data types. Maybe a primary key. The LLM is left to guess what STATUS_CD = 'A' means, what EMP_NM_TXT actually stores, or which of two JOB_ID columns is the right one to join on (and whether the 30-character pre-12c column-name truncations changed the meaning). That’s why the first SQL most LLMs write against a bare Oracle schema is wrong — not because the LLM is bad, but because it doesn’t have the data it needs to be right, and Oracle’s data dictionary is dense.
Query Streams MCP returns that same schema enriched with what we call Schema Intelligence (SI) — AI-curated metadata that’s generated by running profiling queries against your actual Oracle data before the AI client ever asks. When SI is enabled on a connector and database, every schema tool the AI calls (qs_get_connector_schema, qs_get_table_schema, qs_profile_table, qs_get_relationships) returns the bare schema plus six layers of curated knowledge. The LLM stops guessing.
To make this concrete, here is what the AI client gets back from a single qs_get_table_schema call against a typical Oracle HR-style schema (employees, departments, jobs, locations, job_history) — first without Schema Intelligence, then with it.
The six layers Schema Intelligence adds
Each layer addresses a class of question the LLM would otherwise guess at. The opt-in SI profiling pass runs read-only against your Oracle data without changing your schema. what Schema Intelligence adds and how it stays current →
AI-curated descriptions
Plain-English purpose for every schema, table, and column — generated once, refreshed when your Oracle schema changes. Confidence-scored; user-authored descriptions always win.
current and historical.”
Table classifications
Each table tagged FACT (transactional events), DIM (descriptive reference), or LOOKUP (small code maps), plus a business domain — hr, sales, finance, support, and 15 more.
jobs [LOOKUP, domain:hr]
Semantic types per column
Eighteen types — currency, email, date_iso, status_code, percentage, ranking_position, identifier, url, person_name, and more. The AI generates dialect-correct Oracle SQL (SYSDATE, NVL, FETCH FIRST n ROWS ONLY) appropriate to each type.
commission_pct: percentage
Sample values from real data
Random rows surfaced to the LLM so it recognises patterns no Oracle schema can show — formatting conventions, encoded VARCHAR2 values, naming styles, and the actual shape of your strings.
‘LDEHAAN’, ‘AHUNOLD’]
Enum detection with distributions
Low-cardinality columns (50 or fewer distinct values, at most 5% of rows unique) mapped to their full value list with row counts. The AI never guesses Oracle casing or job-code spelling.
| ST_CLERK (10%) | …
Implicit foreign-key discovery
Cross-table data overlap analysis finds joins that aren’t declared as DDL constraints (and confirms the ones that are). Stored alongside formal Oracle FKs with confidence scores, returned by qs_get_relationships.
departments.department_id (conf 0.99)
Same prompt, different SQL
The proof is in the SQL the AI tool actually writes. Same Cursor session, same Claude model, same prompt — “Show me the top 5 highest-paid employees who joined in the last year, including their total compensation and department.” Without Schema Intelligence the LLM guesses with PostgreSQL-flavored syntax that Oracle rejects. With it, the LLM knows the dialect.
si_recommendation block telling the AI what it’s missing, including a one-call option to enable SI mid-conversation via qs_request_si_analysis. how Schema Intelligence runs and how long it takes →
MCP not for you? Try Nova AI instead.
Skip the JSON config entirely: Nova AI is built into the Query Streams web portal and asks the same plain-English questions against your Oracle connector — same agent, same read-only enforcement, same Schema Intelligence, no MCP plumbing.
Meet Nova AIPrerequisites
Before you start, make sure you have:
- A free Query Streams account at my.querystreams.com.
- The Query Streams Network Agent installed on a machine that can reach your Oracle Database — see Download the Query Streams Agent.
- An Oracle connector configured against the agent — see the existing connector setup guides for the TNS connection string. The agent holds the Oracle user password (or wallet, Kerberos, or directory-service credentials); the AI tool never touches them.
- Any MCP-capable AI client. We’ll show Cursor, Claude Desktop, ChatGPT, and Grok in this guide; if you use Windsurf, Zed, Continue, Cline, VS Code Copilot, Codex, or Goose, the config block is essentially the same.
- Five minutes.
Drop it into your AI client
One JSON snippet for Cursor, Claude, ChatGPT, or Grok. Same key everywhere.
Ask a question
“What’s our average employee tenure by department?” — the AI calls the right tools, you get the answer.
Step 1: Generate an MCP key in Query Streams
Sign in to Query Streams and open the MCP page (or sign in first at my.querystreams.com and click MCP in the left navigation). Click Generate key, give the key a recognizable name (something like cursor-laptop or claude-desktop), and pick the scopes you want this key to have:
read— the AI can browse connectors and read schema. Required for everything else.analyze— the AI can profile tables and discover relationships (sample values, distributions, semantic types). Optional but strongly recommended for Oracle work, where understanding the shape of your data matters when the LLM is generating joins across legacy schemas.execute— the AI can actually run SQL. Without this, the AI is read-only against schema metadata only.
For a typical “let Claude analyse my Oracle data” workflow, all three scopes are appropriate. For a key you’re handing to a teammate or a less-trusted client, drop execute and let them browse only. You can revoke any key at any time from the same page; the AI client will see MCP_KEY_REVOKED on its next call and stop working immediately. There’s no propagation delay.
Copy the key now — Query Streams shows it once, then stores only a hash. If you lose it, generate a new one. The key looks like qsmcp_ followed by 48 random characters and is what your AI client sends in the X-MCP-Key request header.
Step 2: Add Query Streams MCP to your AI client
The configuration is the same shape across every MCP-capable client — an MCP server entry pointing at https://mcp.querystreams.com with your key in the X-MCP-Key header. Pick your client below.
// Edit ~/.cursor/mcp.json { "mcpServers": { "querystreams": { "url": "https://mcp.querystreams.com", "headers": { "X-MCP-Key": "qsmcp_PASTE_KEY_HERE" } } } }
// Settings → Developer → Edit Config { "mcpServers": { "querystreams": { "url": "https://mcp.querystreams.com", "headers": { "X-MCP-Key": "qsmcp_PASTE_KEY_HERE" } } } }
// Settings → Apps & Connectors → Add MCP Server URL https://mcp.querystreams.com Auth header X-MCP-Key Header value qsmcp_PASTE_KEY_HERE // Requires a paid ChatGPT plan // (Plus / Pro / Team / Enterprise).
// Grok → Settings → Tools { "mcp_servers": [{ "name": "querystreams", "url": "https://mcp.querystreams.com", "auth_header": "X-MCP-Key", "auth_value": "qsmcp_..." }] }
Restart your AI client. On its next start it will discover the eight Query Streams MCP tools listed above and surface them in its tool palette. In Cursor and Claude Desktop you can verify by typing “list connectors” — the AI should call qs_list_connectors and return your Oracle connector along with anything else you have configured.
Step 3: Ask the AI an Oracle question
You don’t write SQL — the AI does. You ask a question, the AI picks the right MCP tool, the agent runs the query against your Oracle Database, and the answer comes back as text plus tables. Three example prompts to try first:
hr.employees and hr.departments tables, then qs_run_query with a SELECT that joins them on department_id and computes AVG(MONTHS_BETWEEN(SYSDATE, e.hire_date) / 12) per department. The result is a ranked table of departments with average tenure in years, head-count, and a confidence note about turnover. You’ll get a written interpretation alongside — which departments are stable, which are growing, which look like attrition risks — that the AI inferred directly from Oracle’s HR data.e.hire_date >= ADD_MONTHS(SYSDATE, -12)), applies NVL(commission_pct, 0) to handle the nullable percentage column Schema Intelligence flagged, joins hr.employees through department_id to hr.departments for context, and ranks by salary with FETCH FIRST 10 ROWS ONLY. The result is a table with employee id, last name, base salary, total compensation including commission, department, and hire date — the AI typically annotates which roles are above their jobs.max_salary band as a follow-up.employees.job_id to operate on the discovered job-code distribution (IT_PROG, SA_REP, ST_CLERK, …), groups hr.employees by job_id with two windowed counts — one filtered to hire_date >= ADD_MONTHS(SYSDATE, -12) and another for the prior 12-month window — then ranks by year-over-year delta. The result is a sorted list of job categories with current head-count, prior-year head-count, absolute change, and percent change. The AI usually flags the fastest-growing role as a hiring-trend signal rather than a one-off rounding artifact.The first time the AI calls a tool, your client may pop up a confirmation prompt asking you to approve the tool call — that’s MCP’s standard consent flow, not anything Query Streams adds. Approve once and the AI proceeds with the rest of the conversation freely. You can revisit the consent at any time in your client’s settings.
Honest billing notice: MCP usage is charged on uncompressed bytes
Query Streams’ Excel add-in, Google Sheets add-on, web Query Builder, and Nova AI all run over our compressed cloud link — we measure and bill compressedBytes against your data realm. The MCP transport (Streamable HTTP per the official MCP spec) does not reliably support compression end-to-end across every client and intermediate proxy, so we measure and bill uncompressedBytes for MCP traffic.
- What this means: a 5 MB Oracle aggregate query costs ~5 MB of your data realm when fetched via MCP, vs. ~700 KB – 1.2 MB via Excel / Sheets / Nova / the Query Builder. Oracle data with repeated
VARCHAR2values,job_idcodes, anddepartment_namedimensions compresses ~5x via LZ4 on the other transports. Same data, different transport, different billable size. - What you can do: for very large recurring queries (e.g. 100K+ row exports out of
hr.job_historyor audit tables), prefer the Excel / Sheets / Nova path. For interactive AI tool calls (the typical 100–5,000 row Oracle response that fits in an LLM context), MCP is the right choice and the cost difference is in cents.
Frequently asked questions
Do I need to open ports or run a VPN to use this? +
https://mcp.querystreams.com from the public internet — if outbound HTTPS works on the agent host, MCP works. See how the outbound-only connection works →
Which AI tools can I use with Query Streams MCP? +
Can I revoke an MCP key? +
/mcp page, per-org via plan settings, and platform-level), none of which need a database password rotation or agent restart. More on MCP key security →
How is MCP usage billed against my data realm? +
compressedBytes); MCP runs over Streamable HTTP, which doesn’t reliably support compression end-to-end through every client and proxy, so we bill uncompressedBytes. A 5 MB Oracle aggregate query returned to Excel typically costs ~700 KB – 1.2 MB of your data realm; the same 5 MB result returned to Cursor over MCP costs ~5 MB. Oracle data with repeated VARCHAR2 values compresses ~5x via LZ4 on the other transports. We’re transparent about it because we’d rather you know up front than be surprised at the end of the billing cycle.
Does Query Streams MCP work with my Oracle Autonomous Database, Oracle XE, or Oracle on RAC clusters? +
How does this differ from running an open-source Oracle MCP server myself? +
event_logs, and the same data-realm billing pipeline you already use — none of which a direct Oracle MCP gives you.
What happens if the AI tries to write or delete data? +
qs_run_query call is parsed by a hardcoded read-only validator that allows only SELECT, WITH, and EXPLAIN PLAN statements; anything else returns READONLY_VIOLATION and never reaches Oracle. The validator runs in the agent process on your network, not in the cloud, so a compromised cloud surface couldn’t bypass it. (You can layer an Oracle-side read-only user on top if you want belt-and-suspenders — create a user with only SELECT privileges on the relevant hr. / sales. / finance. schemas, or grant the SELECT_CATALOG_ROLE for read-only data-dictionary access. The agent’s validator is independent of whatever Oracle grants you’ve configured.)
Can I see what the AI actually asked? +
event_logs with the org, user, key, scope, latency, and result code. The org-admin can answer “who used MCP last week, which connector, and what did they ask?” with a single query. Note that we log the tool name and metadata, not the SQL text or returned rows — those flow through the cloud link and never land in cloud logs. If you want full SQL-text audit, enable database-side auditing on the underlying engine; for Oracle specifically that’s Unified Auditing (12c+, the recommended modern path), the legacy AUDIT statement against SYS.AUD$ / DBA_AUDIT_TRAIL, Fine-Grained Auditing (DBMS_FGA) for column-level scoping, or Oracle Audit Vault and Database Firewall for centralised audit across multiple Oracle instances.
Do I have to run Schema Intelligence to use Query Streams MCP? +
(connector, database) pair, and MCP works fine without it. The AI gets bare schema (types, primary keys, formal foreign keys, indexes) and writes basic queries. With SI enabled, the AI gets six additional layers of curated metadata: (1) AI-curated descriptions on every schema, table, and column; (2) table classifications (FACT for transactional events, DIM for descriptive reference, LOOKUP for small code maps) plus a business domain tag (hr, sales, finance, seo, support, and 14 more); (3) a semantic type on every column (currency, email, date_iso, status_code, percentage, ranking_position, identifier, url, person_name, and 9 more) that drives dialect-correct Oracle SQL generation (SYSDATE, NVL, FETCH FIRST n ROWS ONLY, ADD_MONTHS); (4) sample values from your real data so the LLM recognises patterns no schema can show, including pre-12c truncated column names; (5) enum detection with full value distributions for low-cardinality columns like job_id; and (6) AI-discovered foreign keys based on cross-table data overlap (and confidence-scored enrichment of the FKs Oracle’s data dictionary already declares), surfaced through qs_get_relationships. Without SI, every schema-tool response also carries an si_recommendation block listing exactly what’s missing for the call — the AI can read this and offer to trigger SI mid-conversation via qs_request_si_analysis. Run time scales with table count: a small Oracle schema under 100 tables completes in around 10 minutes; a typical mid-size schema (a few hundred tables) finishes in 15–25 minutes; a large enterprise database with 1,500+ tables can take 45–60 minutes for a full scan. SI runs through your Network Agent against your data (never in the cloud), never writes to your database, never changes your schema, and refreshes incrementally when your schema changes — so subsequent runs after you add or alter tables are much faster than the first one. The end-to-end effect: with SI enabled, your AI client writes correct Oracle SQL on the first try far more often than it does against any “MCP for X” server that just hands the LLM raw ALL_TAB_COLUMNS.
What if I add another connector later, like Stripe or PostgreSQL? +
qs_list_connectors picks it up automatically). One config block buys your whole account, present and future. Why one key covers every connector →
Do I have to set up MCP just to chat with my data? +
Get started
Connect your AI tool to your Oracle Database in five minutes.
One MCP key reaches Oracle, every other database, and every API connector in your Query Streams account — with full audit trail, per-key rate limits, and zero firewall changes. Claude, Cursor, ChatGPT, and Grok all work out of the box.
Related guides: Download the Query Streams Agent | Database Connector Setup | All MCP Server guides | Nova AI text-to-SQL
Category: MCP Server
Tags: mcp, claude, cursor, oracle, oracle-database, database, enterprise, autonomous-database
Meta Description: Connect Oracle Database to Claude or Cursor via Query Streams MCP. Autonomous, RAC, Exadata, 19c. Outbound-only, read-only, 5-min setup.


