EnableYourData.nl

Platform · Module · SQL Explorer

Ask your database. The AI writes the SQL.

The SQL Explorer with AI is ENABLE's query environment on your own PostgreSQL data warehouse. You ask a question in plain language, the AI turns it into SQL and ENABLE checks the query first with a read-only query plan. Then you run it yourself and view the result as a table or chart.

The SQL Explorer with AI lets you ask questions of your own data warehouse, even if you don't know SQL. You type, for example, "Which ten customers had the highest revenue this quarter?", the AI writes a SQL query for it and ENABLE checks that query before anything runs. The calculation is done by your database, not by the language model.

For those who do write SQL, it is a full query editor with tabs, a table browser, parameters and export. The AI then helps you explain or fix a query.

Everything runs read-only. The AI sees the structure of your data warehouse, never the rows of data themselves, and an AI query is never run automatically: you press run yourself.

Features

What SQL Explorer with AI does

Ask in plain language

Describe what you want to know. The AI SQL generator writes a single SELECT query that only uses existing tables and columns, and sets up filter values as {{parameter}} so you can fill them in yourself.

Explain and fix

Have the AI explain a query in plain terms, or give it an error message and get a corrected version back. Useful for inherited or long queries.

Checked with a query plan

Every AI query is checked in advance with a read-only query plan. If the query is wrong or very heavy, ENABLE asks the AI for a better version and shows any warnings.

Strictly read-only

Only SELECT and WITH queries are allowed, inside a read-only transaction. Write statements, system tables and PostgreSQL admin functions are blocked.

Table, chart and export

Search and sort the result, view it as a bar or line chart and export to CSV (opens directly in Excel) or JSON, up to 50,000 rows per export.

Saved queries

Save good queries for your organisation. If you publish one as an API, each publication gets a version number you can roll back to.

How the SQL Explorer with AI works

Text-to-SQL only works well if the AI knows your data warehouse. That is why ENABLE builds a data dictionary for each organisation: all tables with their columns, data types, declared relationships (foreign keys) and an estimate of the number of rows. That dictionary goes to the model together with your question, via the OpenAI API. Rows of data, passwords and connection details are not included.

The AI then writes a single read-only query. ENABLE checks it for forbidden statements and runs a query plan on it. If the query fails, or is unnecessarily heavy (for example a DISTINCT over an entire fact table), ENABLE asks the AI once for an improved version. The query lands in the editor, with a note saying whether the check passed. Only when you press run does it execute on your data warehouse.

Ask your database questions safely

An AI SQL generator on business data needs hard limits, built into the technology and not just into the instructions given to the AI.

  • Only SELECT and WITH, without semicolons; INSERT, UPDATE, DELETE, DROP and similar statements are rejected.
  • PostgreSQL system schemas and admin functions are shielded, even when written in quotes or via escapes.
  • Every query runs in a read-only transaction with a hard timeout (currently 45 seconds).
  • Each organisation can run at most four queries at the same time; on top of that, per-user limits apply to queries, exports and AI requests.
  • Executed, blocked and failed queries are recorded in your organisation's activity log.
  • The database connection password is stored encrypted (AES-256-GCM) and the connection uses SSL by default.

From one-off question to standard query

A good question often comes back. That is why you can save queries under a recognisable name; they are then available to your organisation's client admins. If you work with {{parameters}}, you fill in a period or customer code, for example, on each run, without changing the SQL.

If you want another system to fetch the same figures, publish a saved query as a REST endpoint through the Data API. Each publication gets a version number; the version history shows who published when, and you can roll back to an earlier version. Published queries are also the building blocks for custom dashboards and apps.

DAX queries on your Power BI model

Alongside SQL, a client admin can run DAX queries on the Power BI model linked to the portal. The semantic model panel shows tables, columns and measures; one click puts a field into the editor in DAX notation.

This lets you quickly check whether a measure in Power BI returns the same result as your own SQL. Your organisation's service principal needs Build permissions on the dataset for this.

Limits and availability by role

The SQL Explorer is enabled by default for client admins. Platform admins can also enable it for regular users, per organisation.

FeatureClient adminUser (if enabled)
Run queries and use AIYesYes
Query plan and export (CSV, JSON)YesYes
Save queriesYesNo
DAX on the Power BI modelYesNo
Publish a query as an APIYesNo
Results on screen25 rows per page, max. 20025 rows per page, max. 200

In ENABLE

How the SQL Explorer works in ENABLE

  1. 01

    Connect the data warehouse

    Platform admins connect your organisation's PostgreSQL data warehouse using a read-only database account, over SSL by default. The password is stored encrypted.

  2. 02

    Ask a question or write SQL

    Type a question in plain language or write SQL yourself, with the table browser alongside.

  3. 03

    Check and run

    Review the query the AI suggests, fill in any parameters and run it. The query plan shows you in advance how heavy a query is.

  4. 04

    Save and reuse

    View the result as a table or chart, export it, save the query or publish it as an API for other systems.

FAQ

Frequently asked questions

What is the SQL Explorer with AI?

The SQL Explorer with AI is the query environment in ENABLE that lets you ask questions of your own PostgreSQL data warehouse. You type a question in plain language, the AI writes the SQL and ENABLE checks the query before you run it. If you know SQL, you can use it as a regular query editor.

How does text-to-SQL work in ENABLE?

The AI receives your question and a data dictionary of your data warehouse: tables, columns and relationships. With that it writes a single read-only query, which ENABLE tests in advance with a query plan. The result comes from your own database, not from the language model.

Can the AI SQL generator change or delete data?

No. Only SELECT and WITH queries are allowed and every query runs in a read-only transaction. Write statements, system tables and admin functions are blocked, and an AI query is never run automatically.

Does OpenAI see my business data?

No, not the rows of data. Via the OpenAI API, the AI only receives metadata, such as table and column names, relationships and an estimate of the number of rows, plus your question. Passwords and connection details are never included.

Who can use the SQL Explorer?

Client admins have access by default. Platform admins can also enable the SQL Explorer for regular users per organisation; those users can then run and export queries, but not save, publish or use DAX.

Can I run DAX queries on my Power BI model?

Yes, as a client admin. You switch from SQL to DAX in the editor and run the query on the semantic model behind your Power BI dashboards. Your organisation's service principal needs Build permissions on the dataset for this.

Share securely, live fast, no headache

In an online demo we show you the portal: dashboards per role, row-level security, plain-language questions and how we set it up and manage it for you.