12.1.1 ODBC Libraries

Note

This section may be skipped when using a MySQL Workbench binary that is provided by Oracle.

An ODBC Driver Manager library must be present. Both Windows and Mac OS X provides one.

Linux

iODBC: MySQL Workbench binaries provided by Oracle already include iODBC and no additional action is required. If you compile it yourself, you must install iODBC or unixODBC. iODBC is recommended. You can use the iODBC library provided by your distribution.

pyodbc: is the Python module used by MySQL Workbench to interface with ODBC, and may be used to migrate ODBC compliant databases such as PostgreSQL and DB2. In Windows and Mac OS X, it is included with Workbench. In Linux, binaries provided by Oracle also include pyodbc.

If you're using a self-compiled binary, make sure you have the latest version, and that it is compiled against the ODBC manager library that you chose, whether it is iODBC or unixODBC. As of version 3.0.6, pyodbc will compile against unixODBC by default. If you are compiling against iODBC then you must perform the following steps:

  1. Install the development files for iODBC. Usually you just need to install the libiodbc-devel or libiodbc2-dev package provided by your distribution.

  2. In the pyodbc source directory, edit the setup.py file and around line 157, replace the following line: settings['libraries'].append('odbc') with settings['libraries'].append('iodbc')

  3. Execute the following command as the root user: CFLAGS=`iodbc-config --cflags` LDFLAGS=`iodbc-config --libs` python setup.py install