Skip to main content
The SQL editor lets you write, execute, and save SQL queries directly in VexiData. Open it from the user menu at the bottom of the sidebar: click your name, then SQL Editor.

Running a query

1

Select a database

Use the Select connection dropdown in the toolbar to choose which connection to query.
2

Write your SQL

Type your query in the editor. The editor supports syntax highlighting and autocomplete for your table and column names.
3

Execute

Click Run or press Ctrl+Enter (Cmd+Enter on Mac).
Results appear below the editor with:
  • Row count — Total number of rows returned
  • Execution time — How long the query took in milliseconds
  • Data table — Scrollable table with your results
NULL values are shown in italic. Long cell values are cut off to keep the table readable. Click New to clear the editor and start a fresh query.

Limits

The SQL editor is read-only and uses the same safety rules as the AI:
  • Only SELECT, WITH, and EXPLAIN statements run, one per query. Statements that write or change data are rejected, and so are system tables such as pg_* and information_schema.
  • A few keywords are rejected wherever they appear outside quoted strings, including REPLACE, TRUNCATE, MERGE, INTO, and CURRENT_USER. That rules out functions such as REPLACE().
  • Results are capped at 10,000 rows. A larger LIMIT (or TOP on SQL Server) is lowered to 10,000.
  • Queries time out after 30 seconds on PostgreSQL, MySQL, and MariaDB. SQL Server has no execution timeout.
You can only query connections you have access to — see Access to a data source.

Saving queries

Click Save in the toolbar to save the current query for later use. If you loaded a saved query, Save updates it instead of creating a copy (the dialog reads Update Saved Query). After switching to a different connection, it saves a new query. Saved queries are personal — only you can see them — and each one is tied to the database connection it was written for.

Saved queries sidebar

Click Show Saved in the toolbar to open the Saved Queries sidebar (Hide Saved closes it). It lists the saved queries for the selected connection. Each entry shows:
  • Query name and description
  • How many times it’s been run
  • When it was last run
Click a saved query to load it into the editor. Hover over it to reveal the Run query and Delete query buttons.

Keyboard shortcuts