IBM_DB Rails adapter dependencies and consequences

The IBM_DB adapter (ibm_db_adapter.rb) has a direct dependency on the IBM_DB driver, which uses IBM Data Server Driver for ODBC and CLI to connect to IBM data servers. The IBM Call Level Interface (CLI) is a callable SQL interface to IBM data servers, which is Open Database Connectivity (ODBC) compliant.

This dependency has several ramifications for the IBM_DB adapter and driver.
  • Installation of IBM Data Server Driver for ODBC and CLI, which meets the IBM_DB requirement, is required.

    IBM Data Server Driver for ODBC and CLI is included with a full Db2® database install, or you can obtain it separately

    Note: The IBM Data Server Driver for ODBC and CLI is included in the listed client packages:
    • IBM Data Server Client
    • IBM Data Server Runtime Client
    • IBM Data Server Driver Package
  • Driver behavior can be modified outside of a Rails application with use of CLI and IBM® data server driver configuration keywords.

    The CLI keywords that are set in the db2cli.ini file and IBM data server driver configuration keywords in the IBM data server driver configuration file (db2dsdriver.cfg) affect Rails applications in a same way as CLI applications. For example, CLI keywords can be used to set the current schema or alter transactional elements such as turning off autocommit behavior.

  • Any diagnostic gathering requires CLI driver tracing.

    Because all requests through the IBM_DB driver are implemented through IBM Data Server Driver for ODBC and CLI, the CLI trace facility can identify problems for applications that use the IBM_DB adapter and driver.

    A CLI trace captures all of the API calls made by an application to the IBM Data Server Driver for ODBC and CLI (including all input parameters), and it captures all of the values returned from the driver to the application. It is an interface trace that captures how an application interacts with the IBM Data Server Driver for ODBC and CLI and offers information about the inner workings of the driver.