ODBC Database Access
The ODBC standard specifies that applications using ODBC connect to databases through Data Source Names (DSNs) defined in the operating system. With PSQL, you can use DSN connections or DSN-less connection strings. PSQL provides ODBC drivers for communication with the the database engine. These drivers are associated with a DSN or specified in the connection string.
The following sections list the PSQL ODBC drivers and briefly introduce DSN database access and DSN-less connection string access.
PSQL ODBC Driver Names
Communication with the database engine is through a PSQL ODBC driver. The setup will associate the appropriate driver during DSN creation. If you are using connection strings, you must specify the appropriate driver. The following table lists the PSQL ODBC drivers.
1 On Linux and OS X, the system encoding is usually UTF-8, which allows SQL text to contain wide character data. SQL text using UTF‑8 is compatible with the existing Pervasive ODBC Client Interface driver, so an ODBC Unicode driver on Linux or OS X is not required.
2 New or revised 32-bit applications, local or remote, should connect to a named database or use a Client DSN instead of using Engine DSNs. Alternately, applications could use DSN-less connections by specifying “Pervasive ODBC Client Interface.” Avoiding the use of Engine DSNs positions your application for the future when Engine DSNs will no longer be supported in PSQL.
DSN Connections
PSQL does not support File DSNs. You must use User or System DSNs. System DSNs are generally preferred, because they are available to all users on a given computer.
If your ODBC application expects to use DSNs, then the DSN must identify the database.
A PSQL Unicode DSN points to a local or remote named database and is for use with Windows 32-bit or 64-bit applications that use wide character data.
PSQL also provides both 32- and 64-bit non-Unicode DSNs. These also point to a local or remote named database. The 32-bit DSN is referred to as a Client DSN. A DSN on a 64-bit operating system is simply referred to as a 64-bit DSN, without the Client designation and is for use by a 64-bit application.
For setting up and configuring a DSN with the ODBC Administrator, see PSQL DSN Setup.
*Note: PSQL also continues to provide an additional 32-bit Engine DSN. Engine DSNs are deprecated. New or revised 32-bit applications, local or remote, should connect to a named database rather than using Engine DSNs. Avoiding the use of Engine DSNs positions your application for the future when Engine DSNs will no longer be supported in PSQL. An Engine DSN points only to a local named database. Client DSNs may also point to an Engine DSN.
DSN-less Connections
As an alternative to DSNs, applications can use DSN-less connections by specifying the PSQL driver name directly (see ODBC Connection Strings).
DSNs are not required for applications that access PSQL databases only through the Btrieve API or through other SQL access methods, such as ADO.NET. Those access methods use named databases for the connection, which is also an option for ODBC applications.
The PSQL Java utilities do not require DSNs. For example, PCC uses JDBC with named databases, not ODBC.