query_databaseLABSCO SUMMARY
Question your database without handing over write access.
The pairing of a published schema with a read-only query path is what makes it safe to point an assistant at a real database: it can find out what exists before asking, and nothing it sends can change anything.
What it is
A small MariaDB connector: the schema list is published as a resource so the assistant can see what tables exist, and one tool runs read-only queries against them.
What you get
query_database— executes read-only operations against MariaDB- The database's schema list, exposed as a resource the client can read before writing a query
Requirements
A MariaDB instance and credentials, passed either as arguments to uvx mcp-server-mariadb — host, port, user, password, database — or as MARIADB_HOST, MARIADB_USER, MARIADB_PASSWORD, MARIADB_DATABASE and MARIADB_PORT, whose sample value is 3306. On macOS the install can fail with mariadb_config not found: install MariaDB Connector/C with brew install mariadb-connector-c, put its bin directory on your PATH, set MARIADB_CONFIG to the connector's mariadb_config, and run the install again.
Setup effort
One command plus credentials — uvx mcp-server-mariadb, then supply credentials
USE CASES
Answering a question about live data
Read the schema, write the query against the tables that actually exist, and get the rows back in the conversation.
Exploring a database you did not design
The schema resource gives the assistant the table layout before it guesses at column names.
Letting someone query without giving them credentials
The connection details live in the server config, so the person asking never handles the database password.
1 tool
Listed in project docs. Your client may show a different list.
BEFORE YOU INSTALL
What to know first
Tools you get
1 tool named in the project's documentation. query_database runs read-only operations against MariaDB.
Requires
- uvx on PATH
- A MariaDB database you can connect to
- MARIADB_USER in your environment
- MARIADB_PASSWORD in your environment
Where it runs
The documented client runs the server on your machine.
INSTALLATION
Connect your client
Server setup
uvx mcp-server-mariadbMCP Clients
Claude Desktop
{
"mcpServers": {
"mcp_server_mariadb": {
"command": "<YOUR_PATH_TO_UVX>",
"args": [
"mcp-server-mariadb"
],
"env": {
"MARIADB_HOST": "127.0.0.1",
"MARIADB_USER": "<YOUR_MARIADB_USER>",
"MARIADB_PASSWORD": "<YOUR_MARIADB_PASSWORD>",
"MARIADB_DATABASE": "<YOUR_MARIADB_DATABASE>",
"MARIADB_PORT": "3306"
}
}
}
}<YOUR_PATH_TO_UVX> is the full path to your uvx executable. The MARIADB_* values are samples (127.0.0.1, port 3306); yours are your database host, user, password, database name and port.