Configuring Database Connections

There are two methods for connecting to the RDBMS; connection strings and using ODBC drivers. See Database Connections for more information.

Configuring in a Windows environment

For this example you will use ODBC drivers to connect to PostgreSQL:

  1. In the search field next to the start icon, type ODBC and click ODBC Data Sources (64-bit).

    This opens the ODBC Data Source Administrator (64-bit) application.

  2. Click System DNS tab.
  3. Click Add.

    This opens the Create New Data Source dialog box.

  4. Click PostgreSQL ODBC Driver(ANSI).
  5. Click Finish.

    This opens the PostgreSQL ANSI ODBC Driver (psqlODBC) Setup dialog box.

  6. Repeat the above steps and complete the details for the three databases listed below:

Configuring in a UNIX environment

There are a number of different driver managers that you can use to configure ODBC data sources. These instructions are carried out using unixODBC. If you are using a different driver manager, consult the vendor instructions for creating data sources:

  1. Run the command odbcinst -j, and note down the location of the drivers configuration file (odbcinst.ini) and the user data sources configuration file (.odbc.ini).
  2. Open the odbcinst.ini configuration file and ensure that you have something similar to the following:
    [PostgreSQL]
    Description=ODBC for PostgreSQL
    Driver64=/usr/pgsql-10/lib/psqlodbcw.so
    Setup64=/usr/lib64/libodbcpsqlS.so
    FileUsage=1
    Threading=2
    Note: Ensure that the threading setting is specified, this avoids potential problems when performing database operations on multiple threads.

    This might differ depending on the version of PostgreSQL you are running.

See the Configuration Requirements chapter for more configuration information.