DBeaver is a universal SQL client and a database administration tool. It is a free tool, and you can download it from the DBeaver website.
This section describes how to connect DBeaver to Exasol and run an SQL statement.
The following environment is used as an example in the document:
- Community edition of DBeaver
- Windows Operating System
- Exasol SaaS
- DBeaver downloaded and installed. You can install DBeaver in the following ways:
As standalone Application (based on Eclipse)
As set of plug-ins for an existing Eclipse installation
- A running Exasol SaaS database. For more information, see Manage Databases and Clusters.
- Your local IP address should be listed in the allowed IP address list. For more information, see Network Security.
Get Drivers and Connection Details
Before you can proceed with connecting to your database from a tool, download the latest Exasol JDBC driver and get the connection details. Follow these steps to get your connection details:
- Click Databases in the web console to open the Databases page.
- Click on the cluster you want to connect to and then click Connect via tools.
- In the Connect to cluster wizard, enter the IP address of the client or server which will connect to the database and click Add IP. Then click Next. If the IP address was already added, just click Next.
- If not already installed, download the latest JDBC driver for your operating system and install it.
- Click Next and proceed through the wizard until you see your connection details:
- Copy the HOST, PORT, USERNAME, and PASSWORD. You can generate a new Personal Access Token by clicking Generate. You will need this information to connect to your database.
Update the JDBC Driver
Connecting to a SaaS database is only possible using the Exasol 7.1 or later JDBC driver. If you do not have the latest driver, update the driver in DBeaver. You only need to perform these steps once per DBeaver installation.
- Open DBeaver. If the Connect to database dialog is displayed, click Cancel.
- Click Database > Driver Manager.
- In the Name list, select Exasol and click Edit.
- To update the driver, in the Libraries tab, select com.exasol:exasol-jdbc:RELEASE and then click Download/Update.
- In Download driver files screen, click the Version column, select the latest version, and click Download. The version must be greater than 7.1.0.
- Once the download is complete, close the Download driver files.
Connect to your Database
- Click Database > New Database Connection.
- In the Select your database screen, click All, select Exasol, and then click Next.
In the Exasol Connection Settings screen, enter the following connection details
from the Get Drivers and Connection Details procedure:
- Host List: Enter the
Enter the Host string you copied from the web console.
- Port: Enter the port number
- User name:
Enter the user name you copied from the web console.
- Password: Enter your
Personal Access Token you copied from web console.
- Host List: Enter the
- To check your connection with the Exasol database, click Test Connection. If you get a connection exception - authentication failed message, recheck the connection string and Personal Access Token information.
Exasol database is now listed in the Database Navigator section in DBeaver.
Execute SQL Statements
Before you continue to execute SQL statements, ensure the option for enhanced metadata usage is checked.
- Click Window > Preferences > Connections > Metadata, and, if necessary, select the Open separate connection for metadata read check box. To save the changes, click Apply and Close.
- To open an SQL editor, click SQL Editor > SQL Editor.
- Enter an SQL statement in the SQL editor and execute it. The result of the query is shown in the Result tab.
Problem: If a script contains multiple semicolons or newlines, DBeaver will not be able to identify where the script ends.
Solution: The simplest way to get around that problem is to highlight the whole script and execute it as a single step.
Problem: R scripts on DBeaver are not executed.<![CDATA[ ]]>
Solution: The issue occurs when DBeaver uses the platforms linefeed convention CRLF. R scripts need to be complied with the linefeed convention LF. The workaround is to change the line delimiters to LF. To set the linefeed to LF, click File > Convert Line Delimiters to > LF.
After connecting DBeaver to Exasol, you can start loading data into the Exasol database. For more information, see Loading Data.
For more information about DBeaver, see DBeaver Official Documentation.