3.6.6 Preconditions and notes on connecting to Oracle

This subsection describes the preconditions and notes on connecting to Oracle.

Organization of this subsection
(1) Preconditions for Oracle11g
(2) Notes on connecting to Oracle
(3) Method of connecting to Oracle using Oracle RAC

(1) Preconditions for Oracle11g

The preconditions for Oracle11g are as follows:

(2) Notes on connecting to Oracle

Note the following when you connect to Oracle:

(a) Differences in the available J2EE components

The J2EE components available when you use Oracle JDBC Thin Driver to connect to Oracle are as follows:

(b) Settings for preventing the differences in Japanese character code conversion and garbled characters in Oracle JDBC Thin Driver

When the data is stored in the database and when the data is extracted from the database, the JDBC driver converts the character code between Unicode and the database storage code appropriately. The following figure shows the locations where the character code conversion is implemented when you use Oracle JDBC Thin Driver.

Figure 3-18 Locations where the character code conversion is implemented when Oracle JDBC Thin Driver is used

[Figure]

The following table describes the character code conversion executed at each location in the figure.

Table 3-28 Locations where the character code conversion is implemented when Oracle JDBC Thin Driver is used

LocationImplemented content
1When the external data, such as a network or file, is read by the J2EE server, the external data code is converted to Unicode.
2When the data read by the J2EE server is stored in the Oracle server, Unicode is converted to UTF-8. This code conversion is implemented by the JDBC driver part on the J2EE server.
3The Oracle server converter converts UTF-8 to the database storage code. This code conversion is implemented on the Oracle server.
4The Oracle server converter converts the database storage code to UTF-8.
5When the data stored by the J2EE server is obtained from the Oracle server, UTF-8 is converted to Unicode.
6When the data obtained with the J2EE server is written to a network or a file, Unicode is converted to the external data code.

When you use Oracle JDBC Thin Driver, the characters might get garbled due to the differences in the mapping rules supported by the converters for JavaVM and the Oracle server. The garbled characters occur due to the combination of the external data character code and the database storage code, and the combination of converters that perform the character code conversion.

To avoid garbled characters, use the following combinations of the external data character code and the database storage code:

(c) Dedicated server connection

The following functionality is not available for dedicated server connections. To use the following functionality, use a shared server connection. For details, inquire with the Oracle Support Service.

(d) Return value of the select statement during the conclusion of a JTA transaction

When using Oracle with an XA transaction, if you issue the Oracle select statements for multiple databases that were updated in a transaction during the conclusion of a JTA transaction, the return value of each select statement might be different. This is due to the restrictions in the distributed read consistency for Oracle.

(3) Method of connecting to Oracle using Oracle RAC

The method of connecting to Oracle using Oracle RAC varies according to the Oracle version or the functionality used for load balancing. The following table describes the mapping between the Oracle version, the functionality used for load balancing, and the RAR file used.

Table 3-29 Mapping between the Oracle version, functionality used, and the RAR file used

Oracle versionFunctionality used for load balancingDB Connector RAR file name
  • Oracle10g
  • Oracle11g
Application Server functionality (Connection pool clustering functionality)DBConnector_CP_ClusterPool_Root.rar
DBConnector_Oracle_CP_ClusterPool_Member.rar
Oracle functionalityDBConnector_Oracle_CP.rar
DBConnector_Oracle_CP_Cosminexus_RM.rar