> # Technical Reference

> ### ODBC Versions Supported

> The Easysoft ODBC-ODBC Bridge supports most of ODBC 2.0 and ODBC 2.5, and all of ODBC 3.0. All the ODBC 2.0 and 2.5 API required to run Perl DBD:ODBC, PHP or mxODBC is present, but the full API of these deprecated versions is not supported as new applications will be written using the ODBC 3.0 API. The ODBC 3.0 API is supported in its entirety.

> ### ODBC API Supported

> This section documents the ODBC-ODBC Bridge API where it differs to the ODBC API.

> #### Modifications to the API

> On non-Windows platforms `SQLDrivers` is implemented by the ODBC-ODBC Bridge even though it is a driver manager function. This is primarily for Perl DBD::ODBC 0.21 support. The ODBC-ODBC Bridge only returns details about itself and no other drivers.

> `SQLBrowseConnect` is a slightly uncomfortable API in the context of an ODBC-ODBC bridge. Normally, `SQLBrowseConnect` provides an iterative method of discovering and enumerating the attributes and attribute values required to connect to a data source. Each call to `SQLBrowseConnect` returns successive levels of attributes and attribute values. When all levels have been enumerated, a connection to the data source is completed and a complete connection string is returned by `SQLBrowseConnect`.

> This process works fine when `SQLBrowseConnect` is called for a driver on the local machine but when you introduce a bridge there are in effect two levels of browsing. The first level will browse the local datasources (defined in your `odbc.ini` file or the registry) but these point to another real datasource on a remote machine.

> For this release of the Easysoft ODBC-ODBC Bridge, `SQLBrowseConnect` only supports browsing the OOB data sources on the local machine. If the user then selects one of these to connect to, they will be prompted for ODBC-ODBC Bridge attributes such as `SERVER`, `TRANSPORT`, `PORT`, `LOGINUSER`, `LOGINAUTH`, `TARGETUSER` and `TARGETAUTH`.

> Once sufficient attributes have been defined to allow a bridge connection to the server, the server side of the OOB will return a list of DSNs retrieved by calling `SQLDataSources`. The browse stops here and so the remote datasource must already be set up with sufficient information to allow a connection.

> This implementation avoids complications with possible clashes of attributes between the OOB and the remote ODBC driver which would make it impossible to return a final connection string which allows a later connection without browsing.

> #### Extra functions

> The non-Windows version of the Easysoft ODBC-ODBC Bridge contains extra functions which are not part of the ODBC API. These were created as a substitute for the valuable functionality of `SQLDataSources` which was not implemented in early pre-releases. They are listed below:

> - `void *enumerate_dsns(void *, unsigned long type);` where type is 0=user DSNs and 1=System DSNs. Call this function to enumerate the list of DSNs in the `odbc.ini` file. The return value is used in subsequent calls to `get_next_dsn()` below. The return value will be NULL if no DSNs can be found (e.g. if there is no `odbc.ini` file).
> - `dsn_details_t *get_next_dsn(void *);` This function returns a pointer to a `dsn_details_t` which contains all the details of the next DSN. You should pass the value returned from `enumerate_dsns()` as a parameter.

> The ODBC-ODBC Bridge now supports `SQLDataSources` so these functions are deprecated.

> [Top] | [Contents] | [Previous] | [Next] | [Index]

| Easysoft - The Home of Data Access |