Loading page...Загружаем страницу...正在加载页面...
AtlasRepo

Speak to your database: Safely read your PG/SQL DB with Query Studio MCP server

Описание и применение

Query Studio позволяет безопасно и прозрачно выполнять запросы к PostgreSQL через чат, генерируя только SELECT‑запросы, проверяя их и ограничивая доступ к данным.

Задача

Users need a conversational interface to query a PostgreSQL database safely, with clear SQL visibility and optional natural‑language explanations.

Результат

Query Studio enables safe, conversational access to a PostgreSQL database, providing transparent SQL, read‑only execution, optional explanations, and multiple safeguards against unsafe queries.

Рабочий процесс

  • 1. Connect to PostgreSQL and fetch schema metadata (tables, columns, types).
  • 2. Cache schema for reuse; refresh on schema changes.
  • 3. Receive user natural‑language request.
  • 4. Use construct_sql tool to generate a single SELECT statement, validating against schema.
  • 5. Execute the accepted SQL via execute_query tool (no AI call).
  • 6. Optionally call summarize_results to explain fetched rows.
  • 7. Display SQL, result table, and optional summary to the user.
  • 8. Enforce limits: 10s statement timeout, 3s lock timeout, max 1,000 rows, read‑only transaction, and a 6‑model‑call loop limit.

Доказательства

Query Studio connects to a PostgreSQL/SQL database and discovers its structure.

Источник

The application validates the completed SQL, accepts one SELECT-based statement, checks its referenced tables against the discovered schema, and rejects writes, deletes, schema changes, and other disallowed forms.

Источник

Execution repeats the checks and requires the incoming SQL to match the statement recorded by construct_sql after normalization.

Источник

  • Дата записи: 2026-11-03T11:14:06.269Z