Configuring access to data sources through JDBC wrapper

To configure the federated server to access JDBC data sources, you must provide the federated server with information about the data sources and objects that you want to access.

Before you begin

The data sources that are accessed through the JDBC API are referred to in this text as JDBC data sources.

  • The JDBC driver must be installed and configured on the computer that acts as the federated server.
  • Check the federated parameter to ensure that federation is enabled.

About this task

Restrictions

  • The JDBC wrapper is supported only in fenced mode.
  • The JDBC wrapper does not support the following functions and statements:
    • LOCK TABLE statements on nicknames
    • Statement-level isolation
  • JDBC data sources do not support positioned update and delete operations.
  • The JDBC wrapper does not support INSERT, UPDATE, or DELETE statements against data sources that restrict the number of active statements for each connection. See the documentation for your data source to determine if the data source restricts the number of active statements for each connection.
  • The JDBC wrapper does not support operations on tables that contain columns with data types that use driver-specific SQL data-type indicators. The type of operations that are not supported include the CREATE NICKNAME and SELECT statements in pass-through sessions. The JDBC wrapper supports only the SQL data type indicators that are defined by the JDBC specification 3.0 and above. See your JDBC driver documentation for the JDBC specifications.
  • The JDBC wrapper does not support LOB in pass-through sessions.
  • Restrictions on type mapping and data type conversion:
    • Unsupported data types: ARRAY, DATALINK, DISTINCT, JAVA_OBJECT, REF, STRUCT and OTHER
    • Data types with limited support:
      • Support for the XML data type is limited. The federated server processes aCLOB data type only if the related JDBC data type is either a CLOB or SQLXML (JDBC 4.0) data type. Otherwise, there is no support for the XML data type.
      • The DBCS and UNICODE data types are stored by the JDBC wrapper as UCS-2.
      • The DECFLOAT data type in Db2® databases and the NUMBER data type in Oracle databases have a larger scope; and their formats can be different to the corresponding JDBC wrapper data types. Mapping to a DECFLOAT or NUMBER data type might cause inaccurate results.

Procedure

  1. Prepare the federated server to access data sources through JDBC wrapper.
  2. Register the JDBC wrapper.
  3. Register the server definitions for an JDBC data source.
  4. Create a user mapping for an JDBC data source.
  5. Test the connection to the JDBC data source server.
  6. Register nicknames for JDBC data source tables and views.