Create an ODBC data source on Mac OS X

The SQL Anywhere ODBC driver must be added before you create the ODBC data source.

Caution

Storing user IDs, encrypted or unencrypted passwords, and database keys in a data source is not recommended.

To add the SQL Anywhere ODBC driver
  1. Launch the ODBC Administrator from /Applications/Utilities.

  2. Select the Drivers tab.

  3. Click Add.

  4. In the Description field, type SQL Anywhere 11.

  5. Click Choose and select the SQL Anywhere ODBC driver in both the Driver File Name and Setup File Name fields. By default, it is located in /Applications/SQLAnywhere11/System/lib/dbodbc11_r.bundle.

    The _r in the bundle name indicates that it is the threaded version of the driver. There is also an unthreaded version (dbodbc11.bundle) for use with unthreaded applications.

  6. Click OK.

To create an ODBC data source

You can add the information with a text editor. The ODBC configuration files are located in /Library/ODBC within your home directory. There is an odbcinst.ini file for driver information and an odbc.ini file for data source information.

You can also use the Data Source utility (dbdsn) to create ODBC data sources on Mac OS X. See Data Source utility (dbdsn).

  1. Launch the ODBC Administrator from /Applications/Utilities.

  2. In the ODBC Administrator, click the User DSN tab, and then click Add.

  3. In the Name list, click SQL Anywhere 11.

  4. Click Finish.

  5. In the Data Source Name field, type Demo11.

  6. Add the following connection parameters. The connection parameters and values are case insensitive.

    Keyword Value
    User ID DBA
    Password sql
    Start Line dbeng11
    Database File /Applications/SQLAnywhere11/System/demo.db
    ThreadManager ON
    Driver SQL Anywhere 11

    For more information about connection parameters, see Connection parameters and network protocol options.

  7. Click OK.

  8. Click Apply.

  9. Press Command+Q to exit the ODBC Administrator.