-
Notifications
You must be signed in to change notification settings - Fork 4.3k
Client Side Scripting
dbeaver-devops edited this page May 22, 2026
·
23 revisions
You can use special commands in the SQL Editor.
These commands are executed on DBeaver's side, not on the server-side.
DBeaver supports the following commands:
| Command | Description |
|---|---|
@ai message
|
Sends a natural-language message to the AI Assistant. The AI processes the message and generates an appropriate SQL query or action based on your input. For more details, see AI command. |
@set var = value |
Sets a script variable. You can use expressions as a value. Variables can be used as SQL queries input parameters. For more information, see Dynamic parameter bindings. |
@unset var |
Unsets a script variable. |
@echo message |
Prints message to output log. You can use a macro in a message (for example ${var}). |
@include fileName |
- Executes a specified file name, - Can be used in scripts, - Opens a new SQL console with the specified file and processes SQL queries as in a regular SQL editor. |
@export { ... } |
Opens the data transfer wizard with predefined settings. For more information, see Export command. |
@pause message
|
Displays a message and waits for the user to press Enter. |
@accept var
|
Reads user input and saves it into a variable. |
You can use multiline commands by enclosing them in @@.
Example:
@@set var = 'long multiline value' @@
| Command | Description |
|---|---|
source fileName |
Executes a SQL script from a file in MySQL CLI syntax. For details, see MySQL documentation for source command. |
| Command | Description |
|---|---|
define var = value |
Declares and assigns a variable in Exasol EXAPlus syntax. For details, see Exasol documentation for DEFINE. |
Note: This feature is available in Lite, Enterprise, and Ultimate editions only.
| Command | Description |
|---|---|
Pause/Pau
|
Displays a message and waits for the user to press Enter. Skips prompt if no text is provided. For details, see Oracle documentation for PAUSE command. |
Accept |
Reads user input and saves it into a variable. Supports datatypes, formats, defaults, prompts, and hidden input. For details, see Oracle documentation for ACCEPT command. |
- Getting started
- DBeaver configuration
-
Security
- Connection settings
- Databases support
- Classic
- Cloud
- Embedded
- File drivers
- Graph
- Database Navigator
- Data Editor
- SQL Editor
- Entity relation diagrams (ERD)
- Cloud services
- AI Smart Assistance
- Data transfer and schema compare
- Task management
- Integrated tools
- Administration
- DBeaver Editions
- Standalone
- Cloud-hosted
- FAQ
- Development