Bad News, DBAs, We Are All Developers Now
I sometimes joke that I’m a Junior Developer and a Principal Database Administrator, which is why I have a Staff level title. I’m not sure …
Read MoreI increasingly hear or read the advice to solve problems by querying MCP servers on production databases.
Meanwhile, I’m reading output from an AI agent that tried to use an MCP server of some sort. And the output is full of things that are obviously wrong/false/dangerous.
It’s expensive and dangerous to trust an AI Agent to query production freely, even with read-only access. You have MUCH safer options which will give you better results, both for human employees and AI Agents.
Whether you’re working with SQL Server, PostgreSQL, Oracle, or Whatever Relational Database, the model that currently makes sense for using AI to soothe your database pains is described on the public preview page for the pganalyze MCP.
As they mention, “there is no direct connection to your database involved.”
Here is the architecture in diagram form:

They do a great job of explaining why this makes sense on that page, so I’m going to take a different approach.
I asked Claude to give me its five strongest arguments (no straw men) of why MCP access to prod databases is good, actually. Let’s walk through those and see how they don’t hold up.
Claude says:
An agent with SELECT-only permissions on a replica can answer operational questions without write exposure — the “stupid” label overclaims by ignoring this configuration.
Amusingly, I didn’t say anything about replicas in my prompt at all– the AI just injected that to try to lower the risk level. You know what you pay a lot of money for? Both Claude code and replicas.
Factors to think through:
We don’t want to be running a bunch of exploratory queries when things go bad. And we don’t even need to. Instead, we can set humans and agents up for success by using AI to build tools to pre-collect and pre-compute the information we need to solve problems. These are all things that can be collected and baselined by normal old predictable code:
An agent with access to this information can much more reliably answer 95% of operational questions with NO direct production access, no expense of replicas, and can even link to you actual data in your monitoring system that substantiates its claims.
Claude continues:
The comparison class isn’t “agents vs. perfection,” it’s “agents vs. humans running ad-hoc queries” — and humans fat-finger DELETE without WHERE too.
Let’s sit with this a second.
We could use AI to make it so that the number of ad-hoc queries and opportunities to screw up a DELETE are dramatically reduced. The fact is, mature OLTP databases are VERY observable– particularly SQL Server is ridiculously so. It’s very well documented how to extract all the information you need to diagnose and troubleshoot what is slowing down or crashing your SQL Server using standard, repeatable, automated methods.
Erik Darling has even given us an MIT Licensed version of this for SQL Server.
We should not extend the bad pattern we already have to AI agents. We should minimize the need for the bad pattern.
A well-designed MCP layer creates a single, structured, logged interface — potentially more traceable than the current reality of engineers, scripts, ORMs, and internal tools all connecting directly with varying levels of logging.
I’ve heard of well-designed databases, too.
I’ve seen thousands of actual databases in hundreds of production environments so far, and one day I’m hoping to find one of those well designed ones.
Humans have been in love with ideals since before Plato named them — and equally good at forgetting that what we actually build and operate exists in the realm of appearances, not Forms.
If agents can’t query production directly, engineers copy data to less-secure environments, export CSVs, or paste results into chat tools — all of which create worse data exposure.
I sometimes wonder if we should start calling database monitoring systems “Agentic Context” now.
Will this rebrand remind us, and the agents, that the majority of troubleshooting is understanding what “normal” looks like and what has changed from “normal”? And monitoring systems are simply a way of collecting/ analyzing/ summarizing descriptions of “normal”, so one can reason about what is different?
Whew, we’re in the home stretch. For this last point, Claude elaborates:
Modern architectures have read replicas, analytics replicas, streaming copies, and data warehouses that are logically production data but architecturally separated. Blanket opposition to “production MCP” conflates genuinely different risk profiles.
There’s another thing that modern architectures also have, which can be far cheaper than replicas or warehouses, which are more efficient by being built for this purpose, and which now have a lot of MIT licensed options….
Monitoring systems. And those pre-compute a huge amount of the information needed to actually solve problems.
Copyright (c) 2025, Catalyze SQL, LLC; all rights reserved. Opinions expressed on this site are solely those of Kendra Little of Catalyze SQL, LLC. Content policy: Short excerpts of blog posts (3 sentences) may be republished, but longer excerpts and artwork cannot be shared without explicit permission.