3. SQL editor
Open an SQL editor with SQL > New SQL editor (Ctrl+N), the toolbar button or by double-clicking a system table. Each editor has its own connection and transaction, so several editors on the same database do not interfere.

SQL editor
3.1 Toolbar
| Command | Description |
|---|---|
| Run (F9) | Runs the selection, or the whole text if nothing is selected |
| Ctrl+Enter | Runs only the statement under the cursor (statements are delimited by ; and blank lines; BEGIN ... END blocks are respected) |
| Run as script | Runs the text as a script (supports SET TERM, several statements, COMMIT) |
| Stop | Cancels the running statement |
| Commit / Rollback | Ends the current transaction |
| Autocommit | Commits every statement automatically |
| Isolation | Read committed, Snapshot or Read only (applies from the next transaction) |
| Open / Save | Loads or saves a .sql file; the tab title follows the file name |
| Max rows | Maximum number of rows fetched |
Statements run in a background thread: the interface stays responsive and Stop is always available.
3.2 Code assistance
The editor (Monaco, the editor of Visual Studio Code) provides SQL syntax highlighting, formatting and find/replace, plus context-aware completion:
- after
alias.orTABLE.it proposes the fields with their types (alsoNEW.andOLD.inside triggers); - tables, views, procedures and functions with their signatures, and SQL keywords;
- Enter or Right arrow accepts the selected suggestion, Ctrl+Space opens the list.
The schema used for completion is reloaded automatically after DDL statements. Completion is also active in the procedure, function, trigger and view editors and in the script runner.
3.3 Results grid
Results appear in the Results tab. The bar above the grid shows whether the result is editable and why not (for example a view without a primary key).

Editable results
- Editable results: when the query reads a single table with a primary or unique key, cells can be edited in place. Insert row..., Delete row, Set NULL and Cell value... (editor for long texts and BLOBs, with hex and image view) are available. Changes go into the open transaction (or are committed at once with Autocommit).
- Search and filter: the box Search results (Ctrl+F) highlights matches, Prev/Next move between them, Filter rows hides non-matching rows.
- Columns: click a title to sort, drag the title border to resize, drag the title to move a column.
- Record: shows the current row vertically (field / value) next to the grid; double-click a value to edit it.

Record view
Right-click on a cell opens the grid menu:
- Copy cell, row, column or the whole result (tab-separated text with headers, ready to paste into Excel);
- Copy as INSERT;
- Export (all formats, see section 7.2);
- Set NULL, Cell value...;
- Freeze columns up to the clicked one, Unfreeze, Auto-size columns;
- Hash of cell value (MD5, SHA-1, SHA-256, SHA-384, SHA-512), copied to the clipboard and, on editable text fields, optionally written into the cell;
- Fill with new GUID (format adapted to the field: 36, 38 or 32 characters, or 16 bytes
CHAR(16) OCTETS).
The message area under the grid shows execution statistics (time, fetched rows, page reads/writes, indexed and sequential reads).
3.4 Execution plan
The Plan tab shows the execution plan of the last statement, as a tree on Firebird 5 (explained plan) and from the monitoring tables on Firebird 3 and 4. It is not available on Firebird 2.5.

Execution plan
3.5 History
Every statement executed is saved in a per-connection history. The History tab lists statements with date, rows and duration; repeated executions of the same statement are grouped.

Query history
Type in the filter box to search, then use Append to editor, Replace editor, Copy, Delete or Clear history. Double-click or Enter inserts the statement in the editor.
3.6 Snippets and templates
- SQL > Insert snippet... inserts a saved piece of SQL at the cursor; Save selection as snippet... stores the current selection.
- Database > New table / view / procedure / function / trigger / sequence / exception / domain / EXECUTE BLOCK asks for a name and opens a new SQL editor on the selected connection with a ready-to-complete template (tab title such as New table: CUSTOMERS). Nothing is executed until you run it.

New table template