ODBC is a widely used Application Programming Interface (API) that enables any application on a client computer to access data sources on a server using SQL.
In an ODBC architecture, applications connect to an ODBC driver manager, which in turn uses a specific ODBC driver to establish a connection to a data source. The client-side component of the driver, which works directly with the application, must strictly comply with the ODBC standard. The application doesn't need to know which database management system (DBMS) is installed on the server. The server-side component of the driver is tailored to a specific database. Due to this architecture, there is no need to configure the application for a particular DBMS.
Advantages of the ODBC Driver for MySQL
Native data connectivity
The MySQL ODBC Driver fully supports standard ODBC API functions and data types and provides easy access to live MySQL data from anywhere. Also, the Driver is compatible with the MySQL API itself.
Real-time data access
The Driver allows accessing data directly from an ODBC-compliant application in real time, which provides a dynamic workspace that adapts and changes as quickly as your data.
Integration
The Driver is compatible with database management solutions, analytics and reporting tools, programming languages, and IDEs. This allows you to view, update, manage, and edit your data using the tool you are working with.
Platforms variety
You can use the ODBC Driver for MySQL with a 32-bit or 64-bit application on both x86 and x64 versions of Windows, Linux, and macOS. No additional drivers or application configurations are required.
Secure connections
To protect your data from unauthorized access, our ODBC driver for MySQL includes a powerful and customizable MySQL database encryption engine. You no longer need to spend money on expensive MySQL client libraries that support encryption.
Installation process
The Devart ODBC Driver is easy to install. All you need is to download it on your computer and follow the installation wizard instructions.
Windows
1. Download the installation executable file of the ODBC Driver for MySQL, open it, and click Next.
2. On the License Agreement page, read the agreement terms. After that, select I accept the agreement and click Next.
3. Browse the destination folder for the Devart ODBC Driver for MySQL and click Next.
4. On the Select Components page, select the components you want to install and click Next.
5. On the Select Start Menu Folder page, specify where the program's shortcuts should be placed. If you don't want the Start Menu folder to be created, select Don't create a Start Menu Folder. Then, click Next.
6. To initiate the installation process, click Install.
7. On the License Information page, choose the license type. If you select Activation Key, insert the corresponding key into the field or click Load Activation Key to browse it on your machine. Then, click Next.
You can install the Devart ODBC Driver for MYSQL on Linux using two installer packages, depending on the distribution you are using.
If you want to install the Driver on Ubuntu, which is a popular open-source Linux distribution based on Debian, then you need to install the .deb package corresponding to the bitness of your operating system.
There are also two ways to install the Driver, either manually or via the command line.
In case you need to install the Driver on CentOS, then it's required to install the .rpm package.
Let's review each method.
GUI installation
1. Download the package of the required bitness from the Devart website.
2. Right-click the downloaded package and choose the necessary option for opening it.
3. In the dialog that opens, click Install.
Command-line installation
1. Open Terminal and go to the folder with the downloaded package.
cd path_to_package
2. To install the Devart ODBC Driver for MySQL from the .deb package, run the following command.
sudo dpkg -i package_name
You should see that the Driver is installed successfully.
To install the Driver from the .rpm package, run the following command.
3. After reading the Software License Agreement, click Agree to go further.
4. In the License Information dialog, you should select the license type and activate the product. If you have no activation key, you can select Trial and use the Driver for evaluation purposes. If you have the activation key, select Activation Key and paste it.
5. To proceed with the installation, click Continue.
6. Finally, click Install.
7. To close the Wizard, click Close.
Configure an ODBC Data Source Name
After the Driver is installed, you should create the Data Source Name (DSN) for your ODBC connection and test it.
Windows
1. Open the ODBC Data Source Administrator and go to the User DSN or System DSN tab. Most applications work with both types, but some require a specific one.
2. Click Add.
3. Select Devart ODBC Driver for MySQL and click Finish.
4. Enter the connection details in the appropriate fields and click Test Connection to confirm connectivity.
You should see the notification about the successful connection.
5. To save the DSN, click OK.
Linux
After you have installed the Driver from the .deb or .rpm package, the DEVART_MYSQL DSN is created. You can use it to test the connection with a MySQL database. To do it:
1. In the /etc/odbc.ini file, find the DEVART_MySQL section, and specify the required connection settings.
User ID=MySQL_username
Password=MySQL_password
Server=MySQL_server_address
Port=MySQL_port
Database=MySQL_database_name
2. In Terminal, run the UnixODBC Test Command utility and test the connection using the following command.
isql -v DEVART_MYSQL
This output means that the connection is successful.
macOS
1. To configure the ODBC Driver for MySQL on macOS, run the iODBC utility of the required bitness. Find DEVART_MYSQL and click Configure.
2. In the dialog that appears, specify the required connection settings and click OK.
3. To verify the connection, click Test.
You should see that the connection was tested successfully and you can use it.
Establish secure connections
SSL connection
SSL (Secure Sockets Layer) is a standard protocol for secure access to a remote machine over untrusted networks.
It runs on top of TCP/IP to secure client-server communications by allowing an SSL-enabled client to authenticate itself to an SSL-enabled server, and vice versa. During server authentication, an SSL-enabled client application uses standard public-key cryptography techniques to verify the server's identity by checking that the server's certificate is issued by a trusted certificate authority (CA) and proves ownership of the public key.
Conversely, SSL client authentication allows the server to validate the client's identity.
The client and server can also authenticate each other using self-signed certificates.
However, self-signed certificates are rarely recommended, except for use on an intranet or a development server.
After establishing an SSL connection, the client and server can exchange messages that are symmetrically encrypted with a shared secret key.
SSL is the recommended method for creating a secure connection to MySQL, due to its simpler configuration and higher performance compared to SSH.
Secure Shell (SSH) is a cryptographic network protocol for secure remote login, command execution, and file transfer over untrusted networks.
SSH employs a client-server architecture, where an SSH client connects to an SSH server.
The client and server authenticate each other and pass commands and output back and forth.
To secure the transmitted data, SSH employs forms of symmetric encryption, asymmetric encryption, and hashing.
If you need to connect to MySQL under restricted connectivity conditions, for example, when the database server is behind a Firewall or when you need to transmit private network data over a public network — you can set up an HTTP tunnel to create a direct network link between two locations.
The tunnel is established by an intermediary called a proxy server.
When the MySQL server is behind a Firewall, the client cannot connect to it directly on the specified port.
However, if the Firewall allows HTTP connections, you can use the ODBC driver with a properly configured web server to connect to the database server.
The driver supports HTTP tunneling based on a PHP script.