Overview
Explorer provides a full-featured SQL editor that can query relational databases as well as files, APIs, and other non-database sources using a unified SQL interface.
Open SQL Editor
The SQL editor is opened from Explorer and runs entirely in the browser.
To open the SQL editor:
-
Select a connection or metadata object
-
Click Develop SQL on the toolbar or use the right-click menu
The SQL editor opens in a new SQL tab.
SQL Editor Layout
The SQL editor consists of:
-
An editor pane for writing SQL
-
A results pane for query output and messages
-
A toolbar with execution and formatting actions
-
Optional execution history panel
You can resize the editor and results panes by dragging the divider between them.
Running SQL Against Database Connections
When working with relational databases, Explorer executes native SQL without modification.
Supported SQL operations
Explorer passes SQL directly to the database using the connection configuration so anything supported by the target database can be executed in Explorer.
Executing SQL and SQL scripts
To execute SQL:
-
Write a query in the editor
-
Click Execute SQL or press Ctrl+F2
To execute SQL script:
-
Write SQL code in the editor
-
Click Execute script or press Ctrl+F3
Query results are displayed in a new dataset tab.
Auto-commit behavior
When running SQL against databases, Explorer always uses auto-commit mode.
This means:
-
DML statements take effect immediately
-
Changes are visible to other users as soon as execution completes
Connection-level transaction settings are ignored in Explorer.
Running SQL Against Non-Database Sources
One of the key features of Etlworks Explorer is the ability to run SQL against non-database data.
Supported non-database sources include:
-
Files and cloud storage
-
Web services and APIs
-
Redis
-
MongoDB
- Message queues
- Inbound email messages and attachmnets
In these cases, SQL is executed against an in-memory dataset produced by parsing the source using the assigned format.
Read how to use SQL to extract data from non relation data sources.
How non-database SQL works
When you execute SQL on a non-database source:
-
Explorer retrieves the data
-
The data is parsed using the assigned format
-
SQL is executed against the parsed dataset
This allows you to filter, project, join, and aggregate non-relational data using SQL syntax.
Run SQL for non-database sources
To run SQL on a non-database source:
-
Select the connection
-
Drill down to a specific file, endpoint, or key
-
Click Develop SQL
The SQL editor opens with the dataset available for querying.
-
Write a query in the editor
-
Click Execute SQL or press Ctrl+F2
Executing Multiple SQL Statements
Explorer supports executing multiple SQL statements in a single editor.
Statements must be separated by semicolons.
Example:
update actor set first_name = 'John' where actor_id = 1;
select * from actor;
select * from film;
Each statement produces:
-
A dataset tab for queries
-
A message tab for DML or DDL statements
Tabs are labeled Dataset1, Dataset2, Message, and so on.
Executing Selected SQL Only
If part of the SQL text is selected in the editor:
-
Only the selected SQL is executed
This allows you to test or rerun individual statements without modifying the rest of the script.
Executing SQL Scripts
SQL scripts are statements that include:
-
Multiple DDL statements
-
Anonymous blocks
-
Procedural SQL
Example:
begin
dbms_output.put_line('Hello There');
end;
To execute a script:
-
Press Ctrl+F3
or
-
Select Execute Script from the editor toolbar
Scripts are executed as a single unit.
SQL Execution History
Explorer records the history of executed SQL statements.
What is recorded
For each execution, Explorer stores:
-
SQL text
-
Executing user
-
Execution time
-
Result status (success or error)
History is stored per connection and shared across users.
Using execution history
To show or hide the history panel:
-
Click Show or Hide Execution History on the SQL editor toolbar
For each history entry, you can:
-
Copy SQL into the editor
-
Replace editor content with SQL from history
-
View SQL in a separate window
This makes it easy to reuse and audit previously executed queries.
Formatting SQL
Explorer can automatically format SQL for readability.
To format SQL:
-
Click Format Code on the SQL editor toolbar
Formatting does not modify SQL semantics. It only adjusts layout and indentation.
Drag and Drop into the SQL Editor
The SQL editor supports drag and drop from the Explorer panels.
You can:
-
Drag tables and views into the editor
-
Drag columns into the editor
-
Drag connections into the SQL tab bar to open a new SQL editor
-
Drag datasets into the Data tab bar to open new grid tabs
-
Drag files or endpoints into the Raw Data tab bar
Drag and drop helps build queries faster and reduces typing errors.
Keyboard Shortcuts
Common SQL editor shortcuts include:
-
Ctrl+F2: Execute SQL
-
Ctrl+F3: Execute SQL script
-
Ctrl+U: Undo
-
Ctrl+Y: Redo
-
Ctrl+Shift+F: Search and replace
A full list of shortcuts is available via the Shortcuts button on the toolbar.
Summary
With the SQL editor in Etlworks Explorer, you can:
-
Run native SQL against relational databases
-
Query non-database data using SQL
-
Execute multiple statements and scripts
-
Reuse SQL from shared execution history
-
Format SQL and use drag and drop for productivity