5.3.1 Configuring a Connector/ODBC DSN on Windows with the ODBC Data Source Administrator GUI

The ODBC Data Source Administrator on Windows lets you create DSNs, check driver installation, and configure ODBC functions such as tracing (used for debugging) and connection pooling. The following are steps for creating and configuring a DSN with the ODBC Data Source Administrator:

  1. Open the ODBC Data Source Administrator.

    Different editions and versions of Windows store the ODBC Data Source Administrator in different locations. For instructions on opening the ODBC Data Source Administrator, see the documentation for you Windows version; these instructions from Microsoft cover some popuar Windows platforms. You should see a window similar to the following when you open the ODBC Data Source Administrator:

    ODBC Data Source Administrator Dialog
  2. To create a System DSN (which will be available to all users), select the System DSN tab. To create a User DSN, which will be available only to the current user, click the Add... button.

  3. Select MySQL ODBC 5.x ANSI or Unicode Driver, then click Finish.

    MySQL ODBC Driver Selection Dialog
  4. You now need to configure the specific fields for the DSN you are creating through the Connection Parameters dialog.

    Add Data Source Name Dialog for Connector/ODBC 5.3

    In the Data Source Name box, enter the name of the data source to access. It can be any valid name that you choose.


    To identify whether a DSN was created using the 32-bit or the 64-bit driver, include the driver being used within the DSN identifier. This will help you to identify the right DSN to use with applications such as Excel that are only compatible with the 32-bit driver. For example, you might add Using32bitCODBC to the DSN identifier for the 32-bit interface and Using64bitCODBC for those using the 64-bit Connector/ODBC driver.

  5. In the Description box, enter some text to help identify the connection.

  6. In the Server field, enter the name of the MySQL server host to access. By default, it is localhost.

  7. In the User field, enter the user name to use for this connection.

  8. In the Password field, enter the corresponding password for this connection.

  9. The Database pop-up should be automatically populated with the list of databases that the user has permissions to access.

  10. To communicate over a different TCP/IP port than the default (3306), change the value of the Port.

  11. Click OK to save the DSN.

To verify the connection using the parameters you have entered, click the Test button. If the connection can be made successfully, you will be notified with a Connection Successful dialog; otherwise, you will be notified with a Connection Failed dialog.

You can configure a number of options for a specific DSN by using the Details button.

Connector/ODBC Connect Options Dialog

The Details button opens a tabbed display where you set additional options: