Loading Data from MySQL

This section describes how to connect MySQL with Exasol and then load data. To view details about data type mappings or to migrate data, see the MySQL to Exasol migration script in our GitHub repository.

Download Driver

Download the JDBC driver for MySQL from the MySQL Connectors page. In the Select Operating System dropdown menu, select Platform Independent.

Configure the Driver in EXAoperation

Do the following to configure the driver in EXAoperation:

  1. Log in to EXAoperation user interface as an Administrator user.
  2. Select Configuration > Software and click the JDBC Drivers tab.
  3. Click Add to add the JDBC driver details.
  4. Enter the following details for the JDBC properties:
    • Driver Name: MySQL
    • Main Class: com.mysql.jdbc.Driver
    • Prefix: jdbc:mysql:
    • Disable Security Manager: Check the box to disable the security manager. This allows the JDBC Driver to access certificate and additional information.
    • Comment: This is an optional field.
  5. Click Add to save the settings.
  6. Select the radio button next to the driver from list of JDBC driver.
  7. Click Choose File to locate the downloaded driver and click Upload to upload the JDBC driver.

Run Statement

Run the following statement to create a connection.

The connection string and authentication details in the example must be replaced with your own values. The MySQL user must have enough privileges to create a connection.

    TO 'jdbc:mysql://' 
    USER 'user_name'
    IDENTIFIED BY 'my_password';

Run the following statement to test the connection.

select * from 
import from JDBC at JDBC_MYSQL
statement 'select ''Connection works'' from dual'

Load Data

You can use the IMPORT statement to load data using the connection you created above. IMPORT supports loading data from a table or a SQL statement.