Skip navigation links

Oracle Database JDBC Java API Reference
11g Release 2

E13995-03


oracle.jdbc
Class OracleConnectionWrapper

java.lang.Object
  extended by oracle.jdbc.OracleConnectionWrapper

All Implemented Interfaces:
java.sql.Connection, OracleConnection

public class OracleConnectionWrapper
extends java.lang.Object
implements OracleConnection

A simple implementation of a connection wrapper which may be nested to any depth.


Nested Class Summary

 

Nested classes/interfaces inherited from interface oracle.jdbc.OracleConnection
OracleConnection.CommitOption, OracleConnection.DatabaseShutdownMode, OracleConnection.DatabaseStartupMode

 

Field Summary
static boolean TRACE
           

 

Fields inherited from interface oracle.jdbc.OracleConnection
ABANDONED_CONNECTION_CALLBACK, ACCESSMODE_BOTH, ACCESSMODE_JAVAPROP, ACCESSMODE_SYSTEMPROP, ALL_CONNECTION_CALLBACKS, CACHE_SIZE_NOT_SET, CONNECTION_PROPERTY_ACCUMULATE_BATCH_RESULT, CONNECTION_PROPERTY_ACCUMULATE_BATCH_RESULT_ACCESSMODE, CONNECTION_PROPERTY_ACCUMULATE_BATCH_RESULT_DEFAULT, CONNECTION_PROPERTY_AUTOCOMMIT, CONNECTION_PROPERTY_AUTOCOMMIT_ACCESSMODE, CONNECTION_PROPERTY_AUTOCOMMIT_DEFAULT, CONNECTION_PROPERTY_COMMIT_OPTION, CONNECTION_PROPERTY_COMMIT_OPTION_ACCESSMODE, CONNECTION_PROPERTY_COMMIT_OPTION_DEFAULT, CONNECTION_PROPERTY_CONVERT_NCHAR_LITERALS, CONNECTION_PROPERTY_CONVERT_NCHAR_LITERALS_ACCESSMODE, CONNECTION_PROPERTY_CONVERT_NCHAR_LITERALS_DEFAULT, CONNECTION_PROPERTY_CREATE_DESCRIPTOR_USE_CURRENT_SCHEMA_FOR_SCHEMA_NAME, CONNECTION_PROPERTY_CREATE_DESCRIPTOR_USE_CURRENT_SCHEMA_FOR_SCHEMA_NAME_ACCESSMODE, CONNECTION_PROPERTY_CREATE_DESCRIPTOR_USE_CURRENT_SCHEMA_FOR_SCHEMA_NAME_DEFAULT, CONNECTION_PROPERTY_DATABASE, CONNECTION_PROPERTY_DATABASE_ACCESSMODE, CONNECTION_PROPERTY_DATABASE_DEFAULT, CONNECTION_PROPERTY_DEFAULT_EXECUTE_BATCH, CONNECTION_PROPERTY_DEFAULT_EXECUTE_BATCH_ACCESSMODE, CONNECTION_PROPERTY_DEFAULT_EXECUTE_BATCH_DEFAULT, CONNECTION_PROPERTY_DEFAULT_LOB_PREFETCH_SIZE, CONNECTION_PROPERTY_DEFAULT_LOB_PREFETCH_SIZE_ACCESSMODE, CONNECTION_PROPERTY_DEFAULT_LOB_PREFETCH_SIZE_DEFAULT, CONNECTION_PROPERTY_DEFAULT_ROW_PREFETCH, CONNECTION_PROPERTY_DEFAULT_ROW_PREFETCH_ACCESSMODE, CONNECTION_PROPERTY_DEFAULT_ROW_PREFETCH_DEFAULT, CONNECTION_PROPERTY_DEFAULT_USE_NIO, CONNECTION_PROPERTY_DEFAULT_USE_NIO_ACCESSMODE, CONNECTION_PROPERTY_DEFAULT_USE_NIO_DEFAULT, CONNECTION_PROPERTY_DEFAULTNCHAR, CONNECTION_PROPERTY_DEFAULTNCHAR_ACCESSMODE, CONNECTION_PROPERTY_DEFAULTNCHAR_DEFAULT, CONNECTION_PROPERTY_DISABLE_DEFINECOLUMNTYPE, CONNECTION_PROPERTY_DISABLE_DEFINECOLUMNTYPE_ACCESSMODE, CONNECTION_PROPERTY_DISABLE_DEFINECOLUMNTYPE_DEFAULT, CONNECTION_PROPERTY_DRIVER_NAME_ATTRIBUTE, CONNECTION_PROPERTY_DRIVER_NAME_ATTRIBUTE_ACCESSMODE, CONNECTION_PROPERTY_DRIVER_NAME_ATTRIBUTE_DEFAULT, CONNECTION_PROPERTY_EDITION_NAME, CONNECTION_PROPERTY_EDITION_NAME_ACCESSMODE, CONNECTION_PROPERTY_EDITION_NAME_DEFAULT, CONNECTION_PROPERTY_ENABLE_DATA_IN_LOCATOR, CONNECTION_PROPERTY_ENABLE_DATA_IN_LOCATOR_ACCESSMODE, CONNECTION_PROPERTY_ENABLE_DATA_IN_LOCATOR_DEFAULT, CONNECTION_PROPERTY_ENABLE_READ_DATA_IN_LOCATOR, CONNECTION_PROPERTY_ENABLE_READ_DATA_IN_LOCATOR_ACCESSMODE, CONNECTION_PROPERTY_ENABLE_READ_DATA_IN_LOCATOR_DEFAULT, CONNECTION_PROPERTY_ENABLE_TEMP_LOB_REF_COUNT, CONNECTION_PROPERTY_ENABLE_TEMP_LOB_REF_COUNT_ACCESSMODE, CONNECTION_PROPERTY_ENABLE_TEMP_LOB_REF_COUNT_DEFAULT, CONNECTION_PROPERTY_FIXED_STRING, CONNECTION_PROPERTY_FIXED_STRING_ACCESSMODE, CONNECTION_PROPERTY_FIXED_STRING_DEFAULT, CONNECTION_PROPERTY_IMPLICIT_STATEMENT_CACHE_SIZE, CONNECTION_PROPERTY_IMPLICIT_STATEMENT_CACHE_SIZE_ACCESSMODE, CONNECTION_PROPERTY_IMPLICIT_STATEMENT_CACHE_SIZE_DEFAULT, CONNECTION_PROPERTY_INCLUDE_SYNONYMS, CONNECTION_PROPERTY_INCLUDE_SYNONYMS_ACCESSMODE, CONNECTION_PROPERTY_INCLUDE_SYNONYMS_DEFAULT, CONNECTION_PROPERTY_INTERNAL_LOGON, CONNECTION_PROPERTY_INTERNAL_LOGON_ACCESSMODE, CONNECTION_PROPERTY_INTERNAL_LOGON_DEFAULT, CONNECTION_PROPERTY_J2EE13_COMPLIANT, CONNECTION_PROPERTY_J2EE13_COMPLIANT_ACCESSMODE, CONNECTION_PROPERTY_J2EE13_COMPLIANT_DEFAULT, CONNECTION_PROPERTY_LOB_STREAM_POS_STANDARD_COMPLIANT, CONNECTION_PROPERTY_LOB_STREAM_POS_STANDARD_COMPLIANT_ACCESSMODE, CONNECTION_PROPERTY_LOB_STREAM_POS_STANDARD_COMPLIANT_DEFAULT, CONNECTION_PROPERTY_MAP_DATE_TO_TIMESTAMP, CONNECTION_PROPERTY_MAP_DATE_TO_TIMESTAMP_ACCESSMODE, CONNECTION_PROPERTY_MAP_DATE_TO_TIMESTAMP_DEFAULT, CONNECTION_PROPERTY_MAX_CACHED_BUFFER_SIZE, CONNECTION_PROPERTY_MAX_CACHED_BUFFER_SIZE_ACCESSMODE, CONNECTION_PROPERTY_MAX_CACHED_BUFFER_SIZE_DEFAULT, CONNECTION_PROPERTY_NET_KEEPALIVE, CONNECTION_PROPERTY_NET_KEEPALIVE_ACCESSMODE, CONNECTION_PROPERTY_NET_KEEPALIVE_DEFAULT, CONNECTION_PROPERTY_OCI_DRIVER_CHARSET, CONNECTION_PROPERTY_OCI_DRIVER_CHARSET_ACCESSMODE, CONNECTION_PROPERTY_OCI_DRIVER_CHARSET_DEFAULT, CONNECTION_PROPERTY_OCI_ENV_HANDLE, CONNECTION_PROPERTY_OCI_ENV_HANDLE_ACCESSMODE, CONNECTION_PROPERTY_OCI_ENV_HANDLE_DEFAULT, CONNECTION_PROPERTY_OCI_ERR_HANDLE, CONNECTION_PROPERTY_OCI_ERR_HANDLE_ACCESSMODE, CONNECTION_PROPERTY_OCI_ERR_HANDLE_DEFAULT, CONNECTION_PROPERTY_OCI_SVC_CTX_HANDLE, CONNECTION_PROPERTY_OCI_SVC_CTX_HANDLE_ACCESSMODE, CONNECTION_PROPERTY_OCI_SVC_CTX_HANDLE_DEFAULT, CONNECTION_PROPERTY_PASSWORD, CONNECTION_PROPERTY_PASSWORD_ACCESSMODE, CONNECTION_PROPERTY_PASSWORD_DEFAULT, CONNECTION_PROPERTY_PRELIM_AUTH, CONNECTION_PROPERTY_PRELIM_AUTH_ACCESSMODE, CONNECTION_PROPERTY_PRELIM_AUTH_DEFAULT, CONNECTION_PROPERTY_PROCESS_ESCAPES, CONNECTION_PROPERTY_PROCESS_ESCAPES_ACCESSMODE, CONNECTION_PROPERTY_PROCESS_ESCAPES_DEFAULT, CONNECTION_PROPERTY_PROTOCOL, CONNECTION_PROPERTY_PROTOCOL_ACCESSMODE, CONNECTION_PROPERTY_PROTOCOL_DEFAULT, CONNECTION_PROPERTY_PROXY_CLIENT_NAME, CONNECTION_PROPERTY_PROXY_CLIENT_NAME_ACCESSMODE, CONNECTION_PROPERTY_PROXY_CLIENT_NAME_DEFAULT, CONNECTION_PROPERTY_REPORT_REMARKS, CONNECTION_PROPERTY_REPORT_REMARKS_ACCESSMODE, CONNECTION_PROPERTY_REPORT_REMARKS_DEFAULT, CONNECTION_PROPERTY_RESOURCE_MANAGER_ID, CONNECTION_PROPERTY_RESOURCE_MANAGER_ID_ACCESSMODE, CONNECTION_PROPERTY_RESOURCE_MANAGER_ID_DEFAULT, CONNECTION_PROPERTY_RESTRICT_GETTABLES, CONNECTION_PROPERTY_RESTRICT_GETTABLES_ACCESSMODE, CONNECTION_PROPERTY_RESTRICT_GETTABLES_DEFAULT, CONNECTION_PROPERTY_RETAIN_V9_BIND_BEHAVIOR, CONNECTION_PROPERTY_RETAIN_V9_BIND_BEHAVIOR_ACCESSMODE, CONNECTION_PROPERTY_RETAIN_V9_BIND_BEHAVIOR_DEFAULT, CONNECTION_PROPERTY_SERVER, CONNECTION_PROPERTY_SERVER_ACCESSMODE, CONNECTION_PROPERTY_SERVER_DEFAULT, CONNECTION_PROPERTY_SET_FLOAT_AND_DOUBLE_USE_BINARY, CONNECTION_PROPERTY_SET_FLOAT_AND_DOUBLE_USE_BINARY_ACCESSMODE, CONNECTION_PROPERTY_SET_FLOAT_AND_DOUBLE_USE_BINARY_DEFAULT, CONNECTION_PROPERTY_SET_NEW_PASSWORD, CONNECTION_PROPERTY_SET_NEW_PASSWORD_ACCESSMODE, CONNECTION_PROPERTY_SET_NEW_PASSWORD_DEFAULT, CONNECTION_PROPERTY_STREAM_CHUNK_SIZE, CONNECTION_PROPERTY_STREAM_CHUNK_SIZE_ACCESSMODE, CONNECTION_PROPERTY_STREAM_CHUNK_SIZE_DEFAULT, CONNECTION_PROPERTY_STRICT_ASCII_CONVERSION, CONNECTION_PROPERTY_STRICT_ASCII_CONVERSION_ACCESSMODE, CONNECTION_PROPERTY_STRICT_ASCII_CONVERSION_DEFAULT, CONNECTION_PROPERTY_THIN_FORCE_DNS_LOAD_BALANCING, CONNECTION_PROPERTY_THIN_FORCE_DNS_LOAD_BALANCING_ACCESSMODE, CONNECTION_PROPERTY_THIN_FORCE_DNS_LOAD_BALANCING_DEFAULT, CONNECTION_PROPERTY_THIN_JAVAX_NET_SSL_KEYSTORE, CONNECTION_PROPERTY_THIN_JAVAX_NET_SSL_KEYSTORE_ACCESSMODE, CONNECTION_PROPERTY_THIN_JAVAX_NET_SSL_KEYSTORE_DEFAULT, CONNECTION_PROPERTY_THIN_JAVAX_NET_SSL_KEYSTOREPASSWORD, CONNECTION_PROPERTY_THIN_JAVAX_NET_SSL_KEYSTOREPASSWORD_ACCESSMODE, CONNECTION_PROPERTY_THIN_JAVAX_NET_SSL_KEYSTOREPASSWORD_DEFAULT, CONNECTION_PROPERTY_THIN_JAVAX_NET_SSL_KEYSTORETYPE, CONNECTION_PROPERTY_THIN_JAVAX_NET_SSL_KEYSTORETYPE_ACCESSMODE, CONNECTION_PROPERTY_THIN_JAVAX_NET_SSL_KEYSTORETYPE_DEFAULT, CONNECTION_PROPERTY_THIN_JAVAX_NET_SSL_TRUSTSTORE, CONNECTION_PROPERTY_THIN_JAVAX_NET_SSL_TRUSTSTORE_ACCESSMODE, CONNECTION_PROPERTY_THIN_JAVAX_NET_SSL_TRUSTSTORE_DEFAULT, CONNECTION_PROPERTY_THIN_JAVAX_NET_SSL_TRUSTSTOREPASSWORD, CONNECTION_PROPERTY_THIN_JAVAX_NET_SSL_TRUSTSTOREPASSWORD_ACCESSMODE, CONNECTION_PROPERTY_THIN_JAVAX_NET_SSL_TRUSTSTOREPASSWORD_DEFAULT, CONNECTION_PROPERTY_THIN_JAVAX_NET_SSL_TRUSTSTORETYPE, CONNECTION_PROPERTY_THIN_JAVAX_NET_SSL_TRUSTSTORETYPE_ACCESSMODE, CONNECTION_PROPERTY_THIN_JAVAX_NET_SSL_TRUSTSTORETYPE_DEFAULT, CONNECTION_PROPERTY_THIN_NAMING_CONTEXT_INITIAL, CONNECTION_PROPERTY_THIN_NAMING_CONTEXT_INITIAL_ACCESSMODE, CONNECTION_PROPERTY_THIN_NAMING_CONTEXT_INITIAL_DEFAULT, CONNECTION_PROPERTY_THIN_NAMING_PROVIDER_URL, CONNECTION_PROPERTY_THIN_NAMING_PROVIDER_URL_ACCESSMODE, CONNECTION_PROPERTY_THIN_NAMING_PROVIDER_URL_DEFAULT, CONNECTION_PROPERTY_THIN_NAMING_SECURITY_AUTHENTICATION, CONNECTION_PROPERTY_THIN_NAMING_SECURITY_AUTHENTICATION_ACCESSMODE, CONNECTION_PROPERTY_THIN_NAMING_SECURITY_AUTHENTICATION_DEFAULT, CONNECTION_PROPERTY_THIN_NAMING_SECURITY_CREDENTIALS, CONNECTION_PROPERTY_THIN_NAMING_SECURITY_CREDENTIALS_ACCESSMODE, CONNECTION_PROPERTY_THIN_NAMING_SECURITY_CREDENTIALS_DEFAULT, CONNECTION_PROPERTY_THIN_NAMING_SECURITY_PRINCIPAL, CONNECTION_PROPERTY_THIN_NAMING_SECURITY_PRINCIPAL_ACCESSMODE, CONNECTION_PROPERTY_THIN_NAMING_SECURITY_PRINCIPAL_DEFAULT, CONNECTION_PROPERTY_THIN_NET_AUTHENTICATION_KRB5_CC_NAME, CONNECTION_PROPERTY_THIN_NET_AUTHENTICATION_KRB5_CC_NAME_ACCESSMODE, CONNECTION_PROPERTY_THIN_NET_AUTHENTICATION_KRB5_CC_NAME_DEFAULT, CONNECTION_PROPERTY_THIN_NET_AUTHENTICATION_KRB5_MUTUAL, CONNECTION_PROPERTY_THIN_NET_AUTHENTICATION_KRB5_MUTUAL_ACCESSMODE, CONNECTION_PROPERTY_THIN_NET_AUTHENTICATION_KRB5_MUTUAL_DEFAULT, CONNECTION_PROPERTY_THIN_NET_AUTHENTICATION_SERVICES, CONNECTION_PROPERTY_THIN_NET_AUTHENTICATION_SERVICES_ACCESSMODE, CONNECTION_PROPERTY_THIN_NET_AUTHENTICATION_SERVICES_DEFAULT, CONNECTION_PROPERTY_THIN_NET_CHECKSUM_LEVEL, CONNECTION_PROPERTY_THIN_NET_CHECKSUM_LEVEL_ACCESSMODE, CONNECTION_PROPERTY_THIN_NET_CHECKSUM_LEVEL_DEFAULT, CONNECTION_PROPERTY_THIN_NET_CHECKSUM_TYPES, CONNECTION_PROPERTY_THIN_NET_CHECKSUM_TYPES_ACCESSMODE, CONNECTION_PROPERTY_THIN_NET_CHECKSUM_TYPES_DEFAULT, CONNECTION_PROPERTY_THIN_NET_CONNECT_TIMEOUT, CONNECTION_PROPERTY_THIN_NET_CONNECT_TIMEOUT_ACCESSMODE, CONNECTION_PROPERTY_THIN_NET_CONNECT_TIMEOUT_DEFAULT, CONNECTION_PROPERTY_THIN_NET_CRYPTO_SEED, CONNECTION_PROPERTY_THIN_NET_CRYPTO_SEED_ACCESSMODE, CONNECTION_PROPERTY_THIN_NET_CRYPTO_SEED_DEFAULT, CONNECTION_PROPERTY_THIN_NET_DISABLE_OUT_OF_BAND_BREAK, CONNECTION_PROPERTY_THIN_NET_DISABLE_OUT_OF_BAND_BREAK_ACCESSMODE, CONNECTION_PROPERTY_THIN_NET_DISABLE_OUT_OF_BAND_BREAK_DEFAULT, CONNECTION_PROPERTY_THIN_NET_ENABLE_SDP, CONNECTION_PROPERTY_THIN_NET_ENABLE_SDP_ACCESSMODE, CONNECTION_PROPERTY_THIN_NET_ENABLE_SDP_DEFAULT, CONNECTION_PROPERTY_THIN_NET_ENCRYPTION_LEVEL, CONNECTION_PROPERTY_THIN_NET_ENCRYPTION_LEVEL_ACCESSMODE, CONNECTION_PROPERTY_THIN_NET_ENCRYPTION_LEVEL_DEFAULT, CONNECTION_PROPERTY_THIN_NET_ENCRYPTION_TYPES, CONNECTION_PROPERTY_THIN_NET_ENCRYPTION_TYPES_ACCESSMODE, CONNECTION_PROPERTY_THIN_NET_ENCRYPTION_TYPES_DEFAULT, CONNECTION_PROPERTY_THIN_NET_OLDSYNTAX, CONNECTION_PROPERTY_THIN_NET_OLDSYNTAX_ACCESSMODE, CONNECTION_PROPERTY_THIN_NET_OLDSYNTAX_DEFAULT, CONNECTION_PROPERTY_THIN_NET_PROFILE, CONNECTION_PROPERTY_THIN_NET_PROFILE_ACCESSMODE, CONNECTION_PROPERTY_THIN_NET_PROFILE_DEFAULT, CONNECTION_PROPERTY_THIN_NET_USE_ZERO_COPY_IO, CONNECTION_PROPERTY_THIN_NET_USE_ZERO_COPY_IO_ACCESSMODE, CONNECTION_PROPERTY_THIN_NET_USE_ZERO_COPY_IO_DEFAULT, CONNECTION_PROPERTY_THIN_READ_TIMEOUT, CONNECTION_PROPERTY_THIN_READ_TIMEOUT_ACCESSMODE, CONNECTION_PROPERTY_THIN_READ_TIMEOUT_DEFAULT, CONNECTION_PROPERTY_THIN_SSL_CIPHER_SUITES, CONNECTION_PROPERTY_THIN_SSL_CIPHER_SUITES_ACCESSMODE, CONNECTION_PROPERTY_THIN_SSL_CIPHER_SUITES_DEFAULT, CONNECTION_PROPERTY_THIN_SSL_KEYMANAGERFACTORY_ALGORITHM, CONNECTION_PROPERTY_THIN_SSL_KEYMANAGERFACTORY_ALGORITHM_ACCESSMODE, CONNECTION_PROPERTY_THIN_SSL_KEYMANAGERFACTORY_ALGORITHM_DEFAULT, CONNECTION_PROPERTY_THIN_SSL_SERVER_DN_MATCH, CONNECTION_PROPERTY_THIN_SSL_SERVER_DN_MATCH_ACCESSMODE, CONNECTION_PROPERTY_THIN_SSL_SERVER_DN_MATCH_DEFAULT, CONNECTION_PROPERTY_THIN_SSL_TRUSTMANAGERFACTORY_ALGORITHM, CONNECTION_PROPERTY_THIN_SSL_TRUSTMANAGERFACTORY_ALGORITHM_ACCESSMODE, CONNECTION_PROPERTY_THIN_SSL_TRUSTMANAGERFACTORY_ALGORITHM_DEFAULT, CONNECTION_PROPERTY_THIN_SSL_VERSION, CONNECTION_PROPERTY_THIN_SSL_VERSION_ACCESSMODE, CONNECTION_PROPERTY_THIN_SSL_VERSION_DEFAULT, CONNECTION_PROPERTY_THIN_TCP_NO_DELAY, CONNECTION_PROPERTY_THIN_TCP_NO_DELAY_ACCESSMODE, CONNECTION_PROPERTY_THIN_TCP_NO_DELAY_DEFAULT, CONNECTION_PROPERTY_THIN_VSESSION_ENAME, CONNECTION_PROPERTY_THIN_VSESSION_ENAME_ACCESSMODE, CONNECTION_PROPERTY_THIN_VSESSION_ENAME_DEFAULT, CONNECTION_PROPERTY_THIN_VSESSION_INAME, CONNECTION_PROPERTY_THIN_VSESSION_INAME_ACCESSMODE, CONNECTION_PROPERTY_THIN_VSESSION_INAME_DEFAULT, CONNECTION_PROPERTY_THIN_VSESSION_MACHINE, CONNECTION_PROPERTY_THIN_VSESSION_MACHINE_ACCESSMODE, CONNECTION_PROPERTY_THIN_VSESSION_MACHINE_DEFAULT, CONNECTION_PROPERTY_THIN_VSESSION_OSUSER, CONNECTION_PROPERTY_THIN_VSESSION_OSUSER_ACCESSMODE, CONNECTION_PROPERTY_THIN_VSESSION_OSUSER_DEFAULT, CONNECTION_PROPERTY_THIN_VSESSION_PROCESS, CONNECTION_PROPERTY_THIN_VSESSION_PROCESS_ACCESSMODE, CONNECTION_PROPERTY_THIN_VSESSION_PROCESS_DEFAULT, CONNECTION_PROPERTY_THIN_VSESSION_PROGRAM, CONNECTION_PROPERTY_THIN_VSESSION_PROGRAM_ACCESSMODE, CONNECTION_PROPERTY_THIN_VSESSION_PROGRAM_DEFAULT, CONNECTION_PROPERTY_THIN_VSESSION_TERMINAL, CONNECTION_PROPERTY_THIN_VSESSION_TERMINAL_ACCESSMODE, CONNECTION_PROPERTY_THIN_VSESSION_TERMINAL_DEFAULT, CONNECTION_PROPERTY_TIMESTAMPTZ_IN_GMT, CONNECTION_PROPERTY_TIMESTAMPTZ_IN_GMT_ACCESSMODE, CONNECTION_PROPERTY_TIMESTAMPTZ_IN_GMT_DEFAULT, CONNECTION_PROPERTY_TIMEZONE_AS_REGION, CONNECTION_PROPERTY_TIMEZONE_AS_REGION_ACCESSMODE, CONNECTION_PROPERTY_TIMEZONE_AS_REGION_DEFAULT, CONNECTION_PROPERTY_USE_1900_AS_YEAR_FOR_TIME, CONNECTION_PROPERTY_USE_1900_AS_YEAR_FOR_TIME_ACCESSMODE, CONNECTION_PROPERTY_USE_1900_AS_YEAR_FOR_TIME_DEFAULT, CONNECTION_PROPERTY_USE_FETCH_SIZE_WITH_LONG_COLUMN, CONNECTION_PROPERTY_USE_FETCH_SIZE_WITH_LONG_COLUMN_ACCESSMODE, CONNECTION_PROPERTY_USE_FETCH_SIZE_WITH_LONG_COLUMN_DEFAULT, CONNECTION_PROPERTY_USE_THREADLOCAL_BUFFER_CACHE, CONNECTION_PROPERTY_USE_THREADLOCAL_BUFFER_CACHE_ACCESSMODE, CONNECTION_PROPERTY_USE_THREADLOCAL_BUFFER_CACHE_DEFAULT, CONNECTION_PROPERTY_USER_NAME, CONNECTION_PROPERTY_USER_NAME_ACCESSMODE, CONNECTION_PROPERTY_USER_NAME_DEFAULT, CONNECTION_PROPERTY_WALLET_LOCATION, CONNECTION_PROPERTY_WALLET_LOCATION_ACCESSMODE, CONNECTION_PROPERTY_WALLET_LOCATION_DEFAULT, CONNECTION_PROPERTY_WALLET_PASSWORD, CONNECTION_PROPERTY_WALLET_PASSWORD_ACCESSMODE, CONNECTION_PROPERTY_WALLET_PASSWORD_DEFAULT, CONNECTION_RELEASE_HIGH, CONNECTION_RELEASE_LOCKED, CONNECTION_RELEASE_LOW, DATABASE_CLOSED, DATABASE_NOTOK, DATABASE_OK, DATABASE_TIMEOUT, DCN_BEST_EFFORT, DCN_IGNORE_DELETEOP, DCN_IGNORE_INSERTOP, DCN_IGNORE_UPDATEOP, DCN_NOTIFY_CHANGELAG, DCN_NOTIFY_ROWIDS, DCN_QUERY_CHANGE_NOTIFICATION, END_TO_END_ACTION_INDEX, END_TO_END_CLIENTID_INDEX, END_TO_END_ECID_INDEX, END_TO_END_MODULE_INDEX, END_TO_END_STATE_INDEX_MAX, INVALID_CONNECTION, NTF_AQ_PAYLOAD, NTF_DEFAULT_TCP_PORT, NTF_GROUPING_CLASS, NTF_GROUPING_CLASS_NONE, NTF_GROUPING_CLASS_TIME, NTF_GROUPING_REPEAT_FOREVER, NTF_GROUPING_REPEAT_TIME, NTF_GROUPING_START_TIME, NTF_GROUPING_TYPE, NTF_GROUPING_TYPE_LAST, NTF_GROUPING_TYPE_SUMMARY, NTF_GROUPING_VALUE, NTF_LOCAL_HOST, NTF_LOCAL_TCP_PORT, NTF_QOS_PURGE_ON_NTFN, NTF_QOS_RELIABLE, NTF_TIMEOUT, PROXY_CERTIFICATE, PROXY_DISTINGUISHED_NAME, PROXY_ROLES, PROXY_SESSION, PROXY_USER_NAME, PROXY_USER_PASSWORD, PROXYTYPE_CERTIFICATE, PROXYTYPE_DISTINGUISHED_NAME, PROXYTYPE_USER_NAME, RELEASE_CONNECTION_CALLBACK

 

Fields inherited from interface java.sql.Connection
TRANSACTION_NONE, TRANSACTION_READ_COMMITTED, TRANSACTION_READ_UNCOMMITTED, TRANSACTION_REPEATABLE_READ, TRANSACTION_SERIALIZABLE

 

Constructor Summary
OracleConnectionWrapper()
           
OracleConnectionWrapper(OracleConnection toBeWrapped)
          Construct an instance which wraps the arguement

 

Method Summary
 java.sql.Connection _getPC()
          Return the underlying physical connection if this is a logical connection.
 void abort()
          Calling abort() on an open connection does the following: marks the connection as closed, closes any sockets or other primitive connections to the database, and insures that any thread that is currently accessing the connection will either progress to completion of the JDBC call or throw an exception.
 void applyConnectionAttributes(java.util.Properties connAttr)
          Applies the connection Attributes provided on the underlying PooledConnection.
 void archive(int mode, int aseq, java.lang.String acstext)
          Not implemented.
 void cancel()
          Performs an immediate (asynchronous) termination of any currently executing operation on this connection.
 void clearAllApplicationContext(java.lang.String nameSpace)
          Clear all the attribute/value information in a namespace.
 void clearWarnings()
           
 void close()
           
 void close(int opt)
          If opt is OracleConnection.INVALID_CONNECTION : Closes the given Logical connection, as well the underlying PooledConnection without returning the connection to the cache when called with the parameter INVALID_CONNECTION.
 void close(java.util.Properties connAttr)
          Closes the given Logical connection, and returns the underlying PooledConnection to the implicit connection cache.
 void commit()
           
 void commit(java.util.EnumSet<OracleConnection.CommitOption> flags)
          Commits the transaction with the given options.
 ARRAY createARRAY(java.lang.String typeName, java.lang.Object elements)
          Creates an ARRAY object with the given type name and elements.
 BINARY_DOUBLE createBINARY_DOUBLE(double value)
          Creates a BINARY_DOUBLE that has the given value.
 BINARY_FLOAT createBINARY_FLOAT(float value)
          Creates a BINARY_FLOAT that has the given value.
 DATE createDATE(java.sql.Date value)
          Creates a DATE that has the given value.
 DATE createDATE(java.sql.Date value, java.util.Calendar cal)
          Creates a DATE that has the given value.
 DATE createDATE(java.lang.String value)
          Creates a DATE that has the given value.
 DATE createDATE(java.sql.Time value)
          Creates a DATE that has the given value.
 DATE createDATE(java.sql.Time value, java.util.Calendar cal)
          Creates a DATE that has the given value.
 DATE createDATE(java.sql.Timestamp value)
          Creates a DATE that has the given value.
 DATE createDATE(java.sql.Timestamp value, java.util.Calendar cal)
          Creates a DATE that has the given value.
 INTERVALDS createINTERVALDS(java.lang.String value)
          Creates an INTERVALDS that has the given value.
 INTERVALYM createINTERVALYM(java.lang.String value)
          Creates an INTERVALYM that has the given value.
 NUMBER createNUMBER(java.math.BigDecimal value)
          Creates a new NUMBER that has the given value.
 NUMBER createNUMBER(java.math.BigInteger value)
          Creates a new NUMBER that has the given value.
 NUMBER createNUMBER(boolean value)
          Creates a new NUMBER that has the given value.
 NUMBER createNUMBER(byte value)
          Creates a new NUMBER that has the given value.
 NUMBER createNUMBER(double value)
          Creates a new NUMBER that has the given value.
 NUMBER createNUMBER(float value)
          Creates a new NUMBER that has the given value.
 NUMBER createNUMBER(int value)
          Creates a new NUMBER that has the given value.
 NUMBER createNUMBER(long value)
          Creates a new NUMBER that has the given value.
 NUMBER createNUMBER(short value)
          Creates a new NUMBER that has the given value.
 NUMBER createNUMBER(java.lang.String value, int scale)
          Creates a new NUMBER that has the given value and scale.
 java.sql.Array createOracleArray(java.lang.String arrayTypeName, java.lang.Object elements)
          Creates an Array object with the given type name and elements.
 java.sql.Statement createStatement()
           
 java.sql.Statement createStatement(int resultSetType, int resultSetConcurrency)
           
 java.sql.Statement createStatement(int resultSetType, int resultSetConcurrency, int resultSetHoldability)
           
 TIMESTAMP createTIMESTAMP(java.sql.Date value)
          Creates a new TIMESTAMP with the given value.
 TIMESTAMP createTIMESTAMP(DATE value)
          Creates a new TIMESTAMP with the given value.
 TIMESTAMP createTIMESTAMP(java.lang.String value)
          Creates a new TIMESTAMP with the given value.
 TIMESTAMP createTIMESTAMP(java.sql.Time value)
          Creates a new TIMESTAMP with the given value.
 TIMESTAMP createTIMESTAMP(java.sql.Timestamp value)
          Creates a new TIMESTAMP with the given value.
 TIMESTAMPLTZ createTIMESTAMPLTZ(java.sql.Date value, java.util.Calendar cal)
          Creates a new TIMESTAMPLTZ with the given value.
 TIMESTAMPLTZ createTIMESTAMPLTZ(DATE value, java.util.Calendar cal)
          Creates a new TIMESTAMPLTZ with the given value.
 TIMESTAMPLTZ createTIMESTAMPLTZ(java.lang.String value, java.util.Calendar cal)
          Creates a new TIMESTAMPLTZ with the given value.
 TIMESTAMPLTZ createTIMESTAMPLTZ(java.sql.Time value, java.util.Calendar cal)
          Creates a new TIMESTAMPLTZ with the given value.
 TIMESTAMPLTZ createTIMESTAMPLTZ(java.sql.Timestamp value, java.util.Calendar cal)
          Creates a new TIMESTAMPLTZ with the given value.
 TIMESTAMPTZ createTIMESTAMPTZ(java.sql.Date value)
          Creates a new TIMESTAMPTZ with the given value.
 TIMESTAMPTZ createTIMESTAMPTZ(DATE value)
           
 TIMESTAMPTZ createTIMESTAMPTZ(java.sql.Date value, java.util.Calendar cal)
          Creates a new TIMESTAMPTZ with the given value.
 TIMESTAMPTZ createTIMESTAMPTZ(java.lang.String value)
          Creates a new TIMESTAMPTZ with the given value.
 TIMESTAMPTZ createTIMESTAMPTZ(java.lang.String value, java.util.Calendar cal)
          Creates a new TIMESTAMPTZ with the given value.
 TIMESTAMPTZ createTIMESTAMPTZ(java.sql.Time value)
          Creates a new TIMESTAMPTZ with the given value.
 TIMESTAMPTZ createTIMESTAMPTZ(java.sql.Time value, java.util.Calendar cal)
          Creates a new TIMESTAMPTZ with the given value.
 TIMESTAMPTZ createTIMESTAMPTZ(java.sql.Timestamp value)
          Creates a new TIMESTAMPTZ with the given value.
 TIMESTAMPTZ createTIMESTAMPTZ(java.sql.Timestamp value, java.util.Calendar cal)
          Creates a new TIMESTAMPTZ with the given value.
 AQMessage dequeue(java.lang.String queueName, AQDequeueOptions opt, byte[] tdo)
          Dequeues an AQ message from the queue specified by its name.
 AQMessage dequeue(java.lang.String queueName, AQDequeueOptions opt, java.lang.String typeName)
          Dequeues an AQ message from the queue specified by its name.
 void enqueue(java.lang.String queueName, AQEnqueueOptions opt, AQMessage mesg)
          Enqueues the given AQ message to the queue specified by its name.
 TypeDescriptor[] getAllTypeDescriptorsInCurrentSchema()
          Obtain all the type descriptors associated with object types or array in the schema of this connection.
 java.lang.String getAuthenticationAdaptorName()
          Returns the name of the adaptor that is used for authentication by the thin driver.
 boolean getAutoClose()
          The driver is always in auto-close mode.
 boolean getAutoCommit()
           
 java.sql.CallableStatement getCallWithKey(java.lang.String key)
          getCallWithKey Searches the explicit cache for a match on key.
 java.lang.String getCatalog()
           
 java.util.Properties getConnectionAttributes()
          Returns the connection Attributes set on the underlying PooledConnection.
 int getConnectionReleasePriority()
          Returns the release priority set on the connection
 boolean getCreateStatementAsRefCursor()
          Retrieves the current setting of the createStatementAsRefCursor flag which you can set with the setCreateStatementAsRefCursor method.
 java.lang.String getCurrentSchema()
          Obtains the current schema of the current connection.
 DatabaseChangeRegistration getDatabaseChangeRegistration(int regid)
          Maps an existing registration identified by its ID 'regid' with a new DatabaseChangeRegistration object.
 java.lang.String getDatabaseTimeZone()
          Returns the database timezone.
 java.lang.String getDataIntegrityAlgorithmName()
          Returns the name of the algorithm that is used for data integrity checking by the thin driver on the network.
 int getDefaultExecuteBatch()
          Retrieves the overall connection batch value of this connection.
 int getDefaultRowPrefetch()
          Retrieves the value of row prefetch for all statements associated with this connection and created after this value was set.
 java.util.TimeZone getDefaultTimeZone()
          Returns the TimeZone set through setDefaultTimeZone.
 java.lang.Object getDescriptor(java.lang.String sql_name)
          Gets a Descriptor object corresponding to a sql type.
 java.lang.String getEncryptionAlgorithmName()
          Returns the name of the algorithm that is used for data encryption by the thin driver on the network.
 short getEndToEndECIDSequenceNumber()
          Gets the current end to end tracing context id sequence number.
 java.lang.String[] getEndToEndMetrics()
          Gets the values of the end-to-end metrics, if any.
 boolean getExplicitCachingEnabled()
          getExplicitCachingEnabled Returns true if the explicit cache is currently enabled, false otherwise.
 int getHoldability()
           
 boolean getImplicitCachingEnabled()
          getImplicitCachingEnabled Returns true if the implicit cache is currently enabled, false otherwise.
 boolean getIncludeSynonyms()
          Checks whether or not synonyms information is included in DatabaseMetaData.getColumns.
 java.lang.Object getJavaObject(java.lang.String sql_name)
           
 java.sql.DatabaseMetaData getMetaData()
           
 java.util.Properties getProperties()
          Determines the connection properties.
 boolean getRemarksReporting()
          Checks whether or not a call of getTables or getColumns of the DatabaseMetaData interface will report the REMARKS column.
 boolean getRestrictGetTables()
          Gets the restriction status of the returned data in DatabaseMetaData.getTables.
 java.lang.String getSessionTimeZone()
          Obtain Oracle session time zone region name.
 java.lang.String getSessionTimeZoneOffset()
          Obtain the time zone offset in hours of the current database session.
 java.lang.String getSQLType(java.lang.Object obj)
           
 int getStatementCacheSize()
          getStatementCacheSize Returns the current size of the application cache.
 java.sql.PreparedStatement getStatementWithKey(java.lang.String key)
          getStatementWithKey Searches the explicit cache for a match on key.
 int getStmtCacheSize()
           
 short getStructAttrCsId()
          Obtain the Oracle identifier of the character set used in STRUCT attributes.
 int getTransactionIsolation()
           
 TypeDescriptor[] getTypeDescriptorsFromList(java.lang.String[][] schemaAndTypeNamePairs)
          Obtain the type descriptors associated with object types or arrays from an array of scheama and type names.
 TypeDescriptor[] getTypeDescriptorsFromListInCurrentSchema(java.lang.String[] typeNames)
          Obtain the type descriptors associated with object types or array in a schema from an array of type names.
 java.util.Map getTypeMap()
           
 java.util.Properties getUnMatchedConnectionAttributes()
          Returns the unmatched connection Attributes from the underlying PooledConnection.
 java.lang.String getUserName()
          Gets the user name of the current connection.
 boolean getUsingXAFlag()
          Gets the value of the UsingXA flag which the driver sets to true when using XA to manage distributed transactions.
 java.sql.SQLWarning getWarnings()
           
 boolean getXAErrorFlag()
          Gets the value of the XAError flag which is used with distributed transactions.
 boolean isClosed()
           
 boolean isLogicalConnection()
          Method that returns a boolean indicating whether its a logical connection or not.
 boolean isProxySession()
          Returns true if the current session associated with this connection is a proxy session.
 boolean isReadOnly()
           
 boolean isUsable()
          Identifies whether this connection is still usable for JDBC operations.
 java.lang.String nativeSQL(java.lang.String sql)
           
 void openProxySession(int mode, java.util.Properties prop)
          Opens a new proxy session with the username provided in the prop argument and switches to this new session.

This feature is supported for both thin and oci driver.

Three proxy types are supported :
OracleConnection.PROXYTYPE_USER_NAME : In this type PROXY_USER_NAME needs to be provided in prop.
 void oracleReleaseSavepoint(OracleSavepoint savepoint)
          Removes the given OracleSavepoint object from the current transaction.
 void oracleRollback(OracleSavepoint savepoint)
          Undoes all changes made after the given OracleSavepoint object was set.
 OracleSavepoint oracleSetSavepoint()
          Creates an unnamed savepoint in the current transaction and returns the new OracleSavepoint object that represents it.
 OracleSavepoint oracleSetSavepoint(java.lang.String name)
          Creates a savepoint with the given name in the current transaction and returns the new OracleSavepoint object that represents it.
 int pingDatabase()
          Ping Database server to see if both database and the connection are actively up.
 int pingDatabase(int timeOut)
          ping Database
 java.sql.CallableStatement prepareCall(java.lang.String sql)
           
 java.sql.CallableStatement prepareCall(java.lang.String sql, int resultSetType, int resultSetConcurrency)
           
 java.sql.CallableStatement prepareCall(java.lang.String sql, int resultSetType, int resultSetConcurrency, int resultSetHoldability)
           
 java.sql.CallableStatement prepareCallWithKey(java.lang.String key)
           
 java.sql.PreparedStatement prepareStatement(java.lang.String sql)
           
 java.sql.PreparedStatement prepareStatement(java.lang.String sql, int autoGeneratedKeys)
           
 java.sql.PreparedStatement prepareStatement(java.lang.String sql, int[] columnIndexes)
           
 java.sql.PreparedStatement prepareStatement(java.lang.String sql, int resultSetType, int resultSetConcurrency)
           
 java.sql.PreparedStatement prepareStatement(java.lang.String sql, int resultSetType, int resultSetConcurrency, int resultSetHoldability)
           
 java.sql.PreparedStatement prepareStatement(java.lang.String sql, java.lang.String[] columnNames)
           
 java.sql.PreparedStatement prepareStatementWithKey(java.lang.String key)
           
 void purgeExplicitCache()
          purgeExplicitCache Removes all existing statements from the explicit cache, after which it will be empty.
 void purgeImplicitCache()
          purgeImplicitCache Removes all existing statements from the implicit cache, after which it will be empty.
 void putDescriptor(java.lang.String sql_name, java.lang.Object desc)
          Store the Object Descriptor for later usage.
 AQNotificationRegistration[] registerAQNotification(java.lang.String[] name, java.util.Properties[] options, java.util.Properties globaloptions)
          Registers your interest into being notified when a message is enqueued in a particular queue (or array of queues).
 void registerConnectionCacheCallback(OracleConnectionCacheCallback occc, java.lang.Object userObj, int cbkFlag)
          Registers the connection cache callback on the logical connection This is used in conjunction with the Implicit Connection Cache Properties.
 DatabaseChangeRegistration registerDatabaseChangeNotification(java.util.Properties options)
          Creates a new database change registration.
 void registerSQLType(java.lang.String sql_name, java.lang.Class java_class)
           
 void registerSQLType(java.lang.String sql_name, java.lang.String java_class_name)
           
 void registerTAFCallback(OracleOCIFailover cbk, java.lang.Object obj)
          Register an application TAF Callback instance that will be called when an application failover occurs.
 void releaseSavepoint(java.sql.Savepoint savepoint)
           
 void rollback()
           
 void rollback(java.sql.Savepoint savepoint)
           
 void setApplicationContext(java.lang.String nameSpace, java.lang.String attribute, java.lang.String value)
          Sets a attribute/value pair in a particular namespace in the application context on the server.
 void setAutoClose(boolean autoClose)
          set auto-close mode.
 void setAutoCommit(boolean autoCommit)
           
 void setCatalog(java.lang.String catalog)
           
 void setConnectionReleasePriority(int priority)
          Sets connection release priority.
 void setCreateStatementAsRefCursor(boolean value)
          When this is set to true, any new statements created from this connection will be created as a REF CURSOR.
 void setDefaultExecuteBatch(int batch)
          Sets a default batch value for the Oracle update batching model (the default value is 1).
 void setDefaultRowPrefetch(int value)
          Sets the value of row prefetch for all statements associated with this connection and created after this value was set.
 void setDefaultTimeZone(java.util.TimeZone tz)
          The TimeZone to be used while creating java.sql.Date, java.sql.Time & java.sql.Timestamp.
 void setEndToEndMetrics(java.lang.String[] metrics, short sequenceNumber)
          Sets the values of the end-to-end tracing metrics.
 void setExplicitCachingEnabled(boolean cache)
          setExplicitCachingEnabled Enables or disables the explicit cache.
 void setHoldability(int holdability)
           
 void setImplicitCachingEnabled(boolean cache)
          setImplicitCachingEnabled Enables or disables the implicit cache.
 void setIncludeSynonyms(boolean synonyms)
          Turns on or off retrieval of synonym information in DatabaseMetaData.
 void setPlsqlWarnings(java.lang.String setting)
          Enable/Disable PLSQL Compiler Warnings
 void setReadOnly(boolean readOnly)
           
 void setRemarksReporting(boolean reportRemarks)
          Turns on or off the reporting of the REMARKS columns by the getTables and getColumns calls of the DatabaseMetaData interface.
 void setRestrictGetTables(boolean restrict)
          Turns on or off the restriction of the returned data in DatabaseMetaData.getTables.
 java.sql.Savepoint setSavepoint()
           
 java.sql.Savepoint setSavepoint(java.lang.String name)
           
 void setSessionTimeZone(java.lang.String regionName)
          Set the session time zone.
 void setStatementCacheSize(int size)
          setStatementCacheSize Specifies the size of the size of the application cache (which will be used by both implicit and explicit caching).
 void setStmtCacheSize(int size)
           
 void setStmtCacheSize(int size, boolean clearMetaData)
           
 void setTransactionIsolation(int level)
           
 void setTypeMap(java.util.Map map)
           
 void setUsingXAFlag(boolean value)
          When using distributed transactions with XA, you can set the value of the UsingXA flag.
 void setWrapper(OracleConnection wrapper)
          Set a connection wrapper as the wrapper of this connection.
 void setXAErrorFlag(boolean value)
          Sets the value of the XAError flag which is used with distributed transactions.
 void shutdown(OracleConnection.DatabaseShutdownMode mode)
          Shuts the database server down.
 void startup(OracleConnection.DatabaseStartupMode mode)
          Starts the database server up.
 void startup(java.lang.String startup_str, int mode)
          Not implemented
 void unregisterAQNotification(AQNotificationRegistration registration)
          Deletes a given AQ registration.
 void unregisterDatabaseChangeNotification(DatabaseChangeRegistration registration)
          Deletes a given database change registration.
 void unregisterDatabaseChangeNotification(int registrationId)
          Deletes a given database change registration in the server.
 void unregisterDatabaseChangeNotification(int registrationId, java.lang.String host, int tcpport)
          Deletes a given database change registration in the server.
 void unregisterDatabaseChangeNotification(long registrationId, java.lang.String callback)
          Deletes a given database change registration in the server.
 OracleConnection unwrap()
          Unwrap one level.

 

Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

 

Field Detail

TRACE

public static final boolean TRACE
See Also:
Constant Field Values

Constructor Detail

OracleConnectionWrapper

public OracleConnectionWrapper()

OracleConnectionWrapper

public OracleConnectionWrapper(OracleConnection toBeWrapped)
Construct an instance which wraps the arguement
Parameters:
toBeWrapped -

Method Detail

unwrap

public OracleConnection unwrap()
Unwrap one level. Returns the connection within this wrapper.
Specified by:
unwrap in interface OracleConnection
Returns:

getDatabaseTimeZone

public java.lang.String getDatabaseTimeZone()
                                     throws java.sql.SQLException
Returns the database timezone.
Throws:
java.sql.SQLException

setWrapper

public void setWrapper(OracleConnection wrapper)
Set a connection wrapper as the wrapper of this connection. Recursively sets the wrapper to the lowest level. Thus the physical connection will always know its outermost wrapper The recursion is terminated by the method in oracle.jdbc.driver.OracleConnction which stores its argument.
Specified by:
setWrapper in interface OracleConnection
Parameters:
wrapper -

createStatement

public java.sql.Statement createStatement()
                                   throws java.sql.SQLException
Specified by:
createStatement in interface java.sql.Connection
Throws:
java.sql.SQLException

prepareStatement

public java.sql.PreparedStatement prepareStatement(java.lang.String sql)
                                            throws java.sql.SQLException
Specified by:
prepareStatement in interface java.sql.Connection
Throws:
java.sql.SQLException

prepareCall

public java.sql.CallableStatement prepareCall(java.lang.String sql)
                                       throws java.sql.SQLException
Specified by:
prepareCall in interface java.sql.Connection
Throws:
java.sql.SQLException

nativeSQL

public java.lang.String nativeSQL(java.lang.String sql)
                           throws java.sql.SQLException
Specified by:
nativeSQL in interface java.sql.Connection
Throws:
java.sql.SQLException

setAutoCommit

public void setAutoCommit(boolean autoCommit)
                   throws java.sql.SQLException
Specified by:
setAutoCommit in interface java.sql.Connection
Throws:
java.sql.SQLException

getAutoCommit

public boolean getAutoCommit()
                      throws java.sql.SQLException
Specified by:
getAutoCommit in interface java.sql.Connection
Throws:
java.sql.SQLException

commit

public void commit()
            throws java.sql.SQLException
Specified by:
commit in interface java.sql.Connection
Throws:
java.sql.SQLException

rollback

public void rollback()
              throws java.sql.SQLException
Specified by:
rollback in interface java.sql.Connection
Throws:
java.sql.SQLException

close

public void close()
           throws java.sql.SQLException
Specified by:
close in interface java.sql.Connection
Throws:
java.sql.SQLException

isClosed

public boolean isClosed()
                 throws java.sql.SQLException
Specified by:
isClosed in interface java.sql.Connection
Throws:
java.sql.SQLException

getMetaData

public java.sql.DatabaseMetaData getMetaData()
                                      throws java.sql.SQLException
Specified by:
getMetaData in interface java.sql.Connection
Throws:
java.sql.SQLException

setReadOnly

public void setReadOnly(boolean readOnly)
                 throws java.sql.SQLException
Specified by:
setReadOnly in interface java.sql.Connection
Throws:
java.sql.SQLException

isReadOnly

public boolean isReadOnly()
                   throws java.sql.SQLException
Specified by:
isReadOnly in interface java.sql.Connection
Throws:
java.sql.SQLException

setCatalog

public void setCatalog(java.lang.String catalog)
                throws java.sql.SQLException
Specified by:
setCatalog in interface java.sql.Connection
Throws:
java.sql.SQLException

getCatalog

public java.lang.String getCatalog()
                            throws java.sql.SQLException
Specified by:
getCatalog in interface java.sql.Connection
Throws:
java.sql.SQLException

setTransactionIsolation

public void setTransactionIsolation(int level)
                             throws java.sql.SQLException
Specified by:
setTransactionIsolation in interface java.sql.Connection
Throws:
java.sql.SQLException

getTransactionIsolation

public int getTransactionIsolation()
                            throws java.sql.SQLException
Specified by:
getTransactionIsolation in interface java.sql.Connection
Throws:
java.sql.SQLException

getWarnings

public java.sql.SQLWarning getWarnings()
                                throws java.sql.SQLException
Specified by:
getWarnings in interface java.sql.Connection
Throws:
java.sql.SQLException

clearWarnings

public void clearWarnings()
                   throws java.sql.SQLException
Specified by:
clearWarnings in interface java.sql.Connection
Throws:
java.sql.SQLException

createStatement

public java.sql.Statement createStatement(int resultSetType,
                                          int resultSetConcurrency)
                                   throws java.sql.SQLException
Specified by:
createStatement in interface java.sql.Connection
Throws:
java.sql.SQLException

prepareStatement

public java.sql.PreparedStatement prepareStatement(java.lang.String sql,
                                                   int resultSetType,
                                                   int resultSetConcurrency)
                                            throws java.sql.SQLException
Specified by:
prepareStatement in interface java.sql.Connection
Throws:
java.sql.SQLException

prepareCall

public java.sql.CallableStatement prepareCall(java.lang.String sql,
                                              int resultSetType,
                                              int resultSetConcurrency)
                                       throws java.sql.SQLException
Specified by:
prepareCall in interface java.sql.Connection
Throws:
java.sql.SQLException

getTypeMap

public java.util.Map getTypeMap()
                         throws java.sql.SQLException
Specified by:
getTypeMap in interface java.sql.Connection
Throws:
java.sql.SQLException

setTypeMap

public void setTypeMap(java.util.Map map)
                throws java.sql.SQLException
Specified by:
setTypeMap in interface java.sql.Connection
Throws:
java.sql.SQLException

isProxySession

public boolean isProxySession()
Description copied from interface: OracleConnection
Returns true if the current session associated with this connection is a proxy session.
Specified by:
isProxySession in interface OracleConnection
Returns:

openProxySession

public void openProxySession(int mode,
                             java.util.Properties prop)
                      throws java.sql.SQLException
Description copied from interface: OracleConnection
Opens a new proxy session with the username provided in the prop argument and switches to this new session.

This feature is supported for both thin and oci driver.

Three proxy types are supported :
Roles can also be provided in the property argument. The key is OracleConnection.PROXY_ROLES. The value is a String[] which contains the roles.
Specified by:
openProxySession in interface OracleConnection
Parameters:
mode - has to be either OracleConnection.PROXYTYPE_USER_NAME or OracleConnection.PROXYTYPE_DISTINGUISHED_NAME or OracleConnection.PROXYTYPE_CERTIFICATE
prop - keys/values
Throws:
java.sql.SQLException

archive

public void archive(int mode,
                    int aseq,
                    java.lang.String acstext)
             throws java.sql.SQLException
Description copied from interface: OracleConnection
Not implemented.
Specified by:
archive in interface OracleConnection
Throws:
java.sql.SQLException

getAutoClose

public boolean getAutoClose()
                     throws java.sql.SQLException
Description copied from interface: OracleConnection
The driver is always in auto-close mode.
Specified by:
getAutoClose in interface OracleConnection
Returns:
should always return true
Throws:
java.sql.SQLException - should never been raised
See Also:
setAutoClose

getCallWithKey

public java.sql.CallableStatement getCallWithKey(java.lang.String key)
                                          throws java.sql.SQLException
Description copied from interface: OracleConnection
getCallWithKey Searches the explicit cache for a match on key. If found, the statement is returned, with the paramater and define metadata identical to the last usage. If no match is found, or if explicit caching is not enabled, then null is returned (as opposed to throwing an exception).
Specified by:
getCallWithKey in interface OracleConnection
Parameters:
key - Specified key to search for
Returns:
Throws:
java.sql.SQLException

getDefaultExecuteBatch

public int getDefaultExecuteBatch()
Description copied from interface: OracleConnection
Retrieves the overall connection batch value of this connection.

The batch value from the connection is used for all prepared statements associated with this connection. A different batch value can also be defined for individual prepared statements. This can be done by using OraclePreparedStatement.setExecuteBatch, which will override the default value provided from the connection. Therefore, the batch value returned by this getDefaultExecuteBatch entrypoint is valid for prepared statements for which you have not defined a different batch value.

The following code retrieves the default batch value of the connection conn.
Integer batch_val = ((OracleConnection)conn).getDefaultExecuteBatch();

Specified by:
getDefaultExecuteBatch in interface OracleConnection
Returns:
the batch value
See Also:
OraclePreparedStatement.setExecuteBatch, setDefaultExecuteBatch

getDefaultRowPrefetch

public int getDefaultRowPrefetch()
Description copied from interface: OracleConnection
Retrieves the value of row prefetch for all statements associated with this connection and created after this value was set.

The row-prefetching feature associates an integer row-prefetch setting with a given statement object. JDBC fetches that number of rows at a time from the database during the query. That is, JDBC will fetch N rows that match the query criteria and bring them all back to the client at once, where N is the prefetch setting. Then, once your next calls have run through those N rows, JDBC will go back to fetch the next N rows that match the criteria.

You can set the number of rows to prefetch for a particular Oracle statement (any type of statement). You can also reset the default number of rows that will be prefetched for all statements in your connection with the setDefaultRowPrefetch method. Therefore, the row prefetch value returned by this getDefaultRowPrefetch entrypoint is valid for statements for which you have not defined a different row prefetch value.

The default number of rows to prefetch to the client is 10.

Example where conn is your connection object:
//Get the default row-prefetch setting for this connection
int defRowPref = ((OracleConnection)conn).getDefaultRowPrefetch();

Specified by:
getDefaultRowPrefetch in interface OracleConnection
Returns:
the row prefetch value
See Also:
OracleStatement.setRowPrefetch, setDefaultRowPrefetch

getDescriptor

public java.lang.Object getDescriptor(java.lang.String sql_name)
Description copied from interface: OracleConnection
Gets a Descriptor object corresponding to a sql type.
Specified by:
getDescriptor in interface OracleConnection
Parameters:
sql_name - the sql type
Returns:
the Descriptor Object that matches the sql type
See Also:
putDescriptor, oracle.sql.TypeDescriptor

getEndToEndMetrics

public java.lang.String[] getEndToEndMetrics()
                                      throws java.sql.SQLException
Description copied from interface: OracleConnection
Gets the values of the end-to-end metrics, if any. Does not include the sequence number. If DMS is in use and metrics have been set via DMS, this method will return the metrics set via DMS, not those set via setEndToEndMetrics. The DMS metric override the metrics set by setEndToEndMetrics.
Specified by:
getEndToEndMetrics in interface OracleConnection
Returns:
the metric values as an array of Strings
Throws:
java.sql.SQLException - if an error occurs
See Also:
setEndToEndMetrics

getEndToEndECIDSequenceNumber

public short getEndToEndECIDSequenceNumber()
                                    throws java.sql.SQLException
Description copied from interface: OracleConnection
Gets the current end to end tracing context id sequence number. This could be any of the following values: the value passed in the most recent call to setEndToEndMetrics the value returned by the database after the most recent statement execution the value incremented by JDBC diagnostic messages the value JDBC retrieved from DMS (only in a DMS environment)
Specified by:
getEndToEndECIDSequenceNumber in interface OracleConnection
Returns:
the current ECID sequence number
Throws:
java.sql.SQLException - if an error occurs

getIncludeSynonyms

public boolean getIncludeSynonyms()
Description copied from interface: OracleConnection
Checks whether or not synonyms information is included in DatabaseMetaData.getColumns. By default and for performance reasons it won't but you can change this with the setIncludeSynonyms method.
Specified by:
getIncludeSynonyms in interface OracleConnection
Returns:
true if DatabaseMetaData.getColumns will report information if a table synonym is passed in, and false otherwise
See Also:
setIncludeSynonyms

getRestrictGetTables

public boolean getRestrictGetTables()
Description copied from interface: OracleConnection
Gets the restriction status of the returned data in DatabaseMetaData.getTables.

The default behavior is to return information about all synonyms, including those which do not point to accessible tables or views. But you can change this with the setRestrictGetTables method.

Specified by:
getRestrictGetTables in interface OracleConnection
Returns:
true if the information returned by DatabaseMetaData.getTables is restricted, and false otherwise
See Also:
setRestrictGetTables

getImplicitCachingEnabled

public boolean getImplicitCachingEnabled()
                                  throws java.sql.SQLException
Description copied from interface: OracleConnection
getImplicitCachingEnabled Returns true if the implicit cache is currently enabled, false otherwise. This method is valid on both logical and physical connections.
Specified by:
getImplicitCachingEnabled in interface OracleConnection
Returns:
Throws:
java.sql.SQLException

getExplicitCachingEnabled

public boolean getExplicitCachingEnabled()
                                  throws java.sql.SQLException
Description copied from interface: OracleConnection
getExplicitCachingEnabled Returns true if the explicit cache is currently enabled, false otherwise. This method is valid on both logical and physical connections.
Specified by:
getExplicitCachingEnabled in interface OracleConnection
Returns:
Throws:
java.sql.SQLException

getJavaObject

public java.lang.Object getJavaObject(java.lang.String sql_name)
                               throws java.sql.SQLException
Specified by:
getJavaObject in interface OracleConnection
Throws:
java.sql.SQLException

getRemarksReporting

public boolean getRemarksReporting()
Description copied from interface: OracleConnection
Checks whether or not a call of getTables or getColumns of the DatabaseMetaData interface will report the REMARKS column.

By default and for performance reasons it won't (it will return null) but you can change this with the setRemarksReporting method.

Specified by:
getRemarksReporting in interface OracleConnection
Returns:
true if the DatabaseMetaData calls getTables and getColumns will report the REMARKS column and false otherwise
See Also:
setRemarksReporting

getSQLType

public java.lang.String getSQLType(java.lang.Object obj)
                            throws java.sql.SQLException
Specified by:
getSQLType in interface OracleConnection
Throws:
java.sql.SQLException

getStmtCacheSize

public int getStmtCacheSize()
Specified by:
getStmtCacheSize in interface OracleConnection

getStatementCacheSize

public int getStatementCacheSize()
                          throws java.sql.SQLException
Description copied from interface: OracleConnection
getStatementCacheSize Returns the current size of the application cache. This is valid on both physical and logical connections. If the statement cache has not been initialized with setStatementCacheSize(), then CACHE_SIZE_NOT_SET is returned.
Specified by:
getStatementCacheSize in interface OracleConnection
Returns:
the cache size
Throws:
java.sql.SQLException

getStatementWithKey

public java.sql.PreparedStatement getStatementWithKey(java.lang.String key)
                                               throws java.sql.SQLException
Description copied from interface: OracleConnection
getStatementWithKey Searches the explicit cache for a match on key. If found, the statement is returned, with the paramater and define metadata identical to the last usage. If no match is found, or if explicit caching is not enabled, then null is returned (as opposed to throwing an exception).
Specified by:
getStatementWithKey in interface OracleConnection
Parameters:
key - Specified key to search for
Returns:
Throws:
java.sql.SQLException

getStructAttrCsId

public short getStructAttrCsId()
                        throws java.sql.SQLException
Description copied from interface: OracleConnection
Obtain the Oracle identifier of the character set used in STRUCT attributes. Note that the network transport layer always send structure attributes in the database character set.
Specified by:
getStructAttrCsId in interface OracleConnection
Returns:
the Oracle identifier of the character set.
Throws:
java.sql.SQLException - if Conversion is null
See Also:
oracle.sql.CharacterSet for the set of constants defined for the identifiers."

getUserName

public java.lang.String getUserName()
                             throws java.sql.SQLException
Description copied from interface: OracleConnection
Gets the user name of the current connection.

Example where conn is your connection object:
String UserName = ((OracleConnection)conn).getUserName();

Specified by:
getUserName in interface OracleConnection
Returns:
the user name
Throws:
java.sql.SQLException - if the logical connection is closed

getCurrentSchema

public java.lang.String getCurrentSchema()
                                  throws java.sql.SQLException
Description copied from interface: OracleConnection
Obtains the current schema of the current connection.
Specified by:
getCurrentSchema in interface OracleConnection
Returns:
current_schema value
Throws:
java.sql.SQLException - If there was an error while fetching the results

getUsingXAFlag

public boolean getUsingXAFlag()
Description copied from interface: OracleConnection
Gets the value of the UsingXA flag which the driver sets to true when using XA to manage distributed transactions. If you are not using distributed transactions with the XA library, the value of the UsingXA flag will be false.
Specified by:
getUsingXAFlag in interface OracleConnection
Returns:
true when using XA to manage distributed transactions and false otherwise.
See Also:
setUsingXAFlag

getXAErrorFlag

public boolean getXAErrorFlag()
Description copied from interface: OracleConnection
Gets the value of the XAError flag which is used with distributed transactions.

When using distributed transactions with an XA library, you can ask the driver to raise exception when doing anything that might require a transaction. To do so, set the value of the XAError flag to true with the method setXAErrorFlag.

The default value is false.

Specified by:
getXAErrorFlag in interface OracleConnection
Returns:
false is the normal JDBC usage. true means that the driver will raise an exception when doing anything that might require a transaction.
See Also:
setXAErrorFlag

oracleSetSavepoint

public OracleSavepoint oracleSetSavepoint()
                                   throws java.sql.SQLException
Description copied from interface: OracleConnection
Creates an unnamed savepoint in the current transaction and returns the new OracleSavepoint object that represents it.
Specified by:
oracleSetSavepoint in interface OracleConnection
Returns:
the new OracleSavepoint object
Throws:
java.sql.SQLException - if a database access error occurs or this Connection object is currently in auto-commit mode
See Also:
OracleSavepoint

oracleSetSavepoint

public OracleSavepoint oracleSetSavepoint(java.lang.String name)
                                   throws java.sql.SQLException
Description copied from interface: OracleConnection
Creates a savepoint with the given name in the current transaction and returns the new OracleSavepoint object that represents it.
Specified by:
oracleSetSavepoint in interface OracleConnection
Parameters:
name - a String containing the name of the savepoint
Returns:
the new OracleSavepoint object
Throws:
java.sql.SQLException - if a database access error occurs or this Connection object is currently in auto-commit mode
See Also:
OracleSavepoint

oracleRollback

public void oracleRollback(OracleSavepoint savepoint)
                    throws java.sql.SQLException
Description copied from interface: OracleConnection
Undoes all changes made after the given OracleSavepoint object was set.

This method should be used only when auto-commit has been disabled.

Specified by:
oracleRollback in interface OracleConnection
Parameters:
savepoint - the OracleSavepoint object to roll back to
Throws:
java.sql.SQLException - if a database access error occurs, the OracleSavepoint object is no longer valid, or this Connection object is currently in auto-commit mode
See Also:
OracleSavepoint

oracleReleaseSavepoint

public void oracleReleaseSavepoint(OracleSavepoint savepoint)
                            throws java.sql.SQLException
Description copied from interface: OracleConnection
Removes the given OracleSavepoint object from the current transaction. Any reference to the savepoint after it have been removed will cause an SQLException to be thrown.
Specified by:
oracleReleaseSavepoint in interface OracleConnection
Parameters:
savepoint - the OracleSavepoint object to be removed
Throws:
java.sql.SQLException - if a database access error occurs or the given OracleSavepoint object is not a valid savepoint in the current transaction
See Also:
OracleSavepoint

pingDatabase

public int pingDatabase()
                 throws java.sql.SQLException
Description copied from interface: OracleConnection
Ping Database server to see if both database and the connection are actively up.
Specified by:
pingDatabase in interface OracleConnection
Returns:
DATABASE_OK if the database server is up, and DATABASE_CLOSED if any error occurs.
Throws:
java.sql.SQLException

pingDatabase

public int pingDatabase(int timeOut)
                 throws java.sql.SQLException
Description copied from interface: OracleConnection
ping Database
Specified by:
pingDatabase in interface OracleConnection
Returns:
Throws:
java.sql.SQLException

purgeExplicitCache

public void purgeExplicitCache()
                        throws java.sql.SQLException
Description copied from interface: OracleConnection
purgeExplicitCache Removes all existing statements from the explicit cache, after which it will be empty. This method does not affect the size of the application cache, nor the enabled/disabled status.
Specified by:
purgeExplicitCache in interface OracleConnection
Throws:
java.sql.SQLException

purgeImplicitCache

public void purgeImplicitCache()
                        throws java.sql.SQLException
Description copied from interface: OracleConnection
purgeImplicitCache Removes all existing statements from the implicit cache, after which it will be empty. This method does not affect the size of the application cache, nor the enabled/disabled status.
Specified by:
purgeImplicitCache in interface OracleConnection
Throws:
java.sql.SQLException

putDescriptor

public void putDescriptor(java.lang.String sql_name,
                          java.lang.Object desc)
                   throws java.sql.SQLException
Description copied from interface: OracleConnection
Store the Object Descriptor for later usage.
Specified by:
putDescriptor in interface OracleConnection
Parameters:
sql_name - the sql type
desc - the Object Descriptor associated
Throws:
java.sql.SQLException - if sql_name or desc is null
See Also:
getDescriptor, oracle.sql.TypeDescriptor

registerSQLType

public void registerSQLType(java.lang.String sql_name,
                            java.lang.Class java_class)
                     throws java.sql.SQLException
Specified by:
registerSQLType in interface OracleConnection
Throws:
java.sql.SQLException

registerSQLType

public void registerSQLType(java.lang.String sql_name,
                            java.lang.String java_class_name)
                     throws java.sql.SQLException
Specified by:
registerSQLType in interface OracleConnection
Throws:
java.sql.SQLException

setAutoClose

public void setAutoClose(boolean autoClose)
                  throws java.sql.SQLException
Description copied from interface: OracleConnection
set auto-close mode. Only true is accepted.
Specified by:
setAutoClose in interface OracleConnection
Parameters:
autoClose - the boolean value
Throws:
java.sql.SQLException - when the argument autoClose is false
See Also:
getAutoClose

setDefaultExecuteBatch

public void setDefaultExecuteBatch(int batch)
                            throws java.sql.SQLException
Description copied from interface: OracleConnection
Sets a default batch value for the Oracle update batching model (the default value is 1).

You can reduce the number of round trips to the database, thereby improving application performance, by grouping multiple UPDATE, DELETE, or INSERT statements into a single "batch" and having the whole batch sent to the database and processed in one trip. To do this, you can either use the Oracle update batching model or the batch updates of the Sun Microsystems JDBC 2.0 specification. The standard model is a manual, explicit model (there is no batch value) whereas the Oracle model is an implicit model.

Note: It is important to be aware that you cannot mix theses models. In any single application, you can use the syntax of one model or the other, but not both. The Oracle JDBC driver will throw exceptions when you mix these syntaxes.

The Oracle update batching feature associates a batch value (limit) with each prepared statement object (this way the driver knows in advance how many operations will be batched). With Oracle update batching, instead of the JDBC driver executing a prepared statement each time its executeUpdate method is called, the driver adds the statement to a batch of accumulated execution requests. The driver will pass all the operations to the database for execution once the batch value is reached. For example, if the batch value is 10, then each batch of 10 operations will be sent to the database and processed in one trip.

The following code sets the default batch value to 20 for all prepared statement objects associated with the conn connection object:

((OracleConnection)conn).setDefaultExecuteBatch(20);

Even though this sets the default batch value for all the prepared statements of the connection, you can override it by calling setDefaultBatch on individual Oracle prepared statements. The connection batch value will apply to statement objects created after this batch value was set.

Note that instead of calling setDefaultExecuteBatch, you can set the defaultBatchValue Java property if you use a Java Properties object in establishing the connection.

Types of Statements Supported. As implemented by Oracle, update batching is intended for use with prepared statements, when you are repeating the same statement with different bind variables. Be aware of the following:

Oracle Update Batching Characteristics and Limitations

Specified by:
setDefaultExecuteBatch in interface OracleConnection
Parameters:
batch - your default batch value (default is 1)
Throws:
java.sql.SQLException - if the argument batch is <=0
See Also:
OraclePreparedStatement.setExecuteBatch, getDefaultExecuteBatch

setDefaultRowPrefetch

public void setDefaultRowPrefetch(int value)
                           throws java.sql.SQLException
Description copied from interface: OracleConnection
Sets the value of row prefetch for all statements associated with this connection and created after this value was set.

The row-prefetching feature associates an integer row-prefetch setting with a given statement object. JDBC fetches that number of rows at a time from the database during the query. That is, JDBC will fetch N rows that match the query criteria and bring them all back to the client at once, where N is the prefetch setting. Then, once your next calls have run through those N rows, JDBC will go back to fetch the next N rows that match the criteria.

You can set the number of rows to prefetch for a particular Oracle statement (any type of statement) but this method allows you to reset the default number of rows that will be prefetched for all statements in your connection. The default number of rows to prefetch to the client is 10.

Use the setDefaultRowPrefetch method to set the default number of rows to prefetch, passing in an integer that specifies the desired default. If you want to check the current setting of the default, then use the getDefaultRowPrefetch method. This method returns an integer.

Example where conn is your connection object:
//Set the default row-prefetch setting for this connection to 7
((OracleConnection)conn).setDefaultRowPrefetch(7);

Note 1 : A statement object receives the default row-prefetch setting from the associated connection at the time the statement object is created. Subsequent changes to the connection's default row-prefetch setting have no effect on the statement's row-prefetch setting.

Note 2 : If a column of a result set is of datatype LONG or LONG RAW (that is, the streaming types), JDBC changes the statement's row-prefetch setting to 1, even if you never actually read a value of either of those types.

Note 3 : Do not mix the JDBC 2.0 fetch size API and the Oracle row-prefetching API in your application. You can use one or the other but not both.

Specified by:
setDefaultRowPrefetch in interface OracleConnection
Parameters:
value - the number of rows to prefetch
Throws:
java.sql.SQLException - if the argument value is <=0
See Also:
OracleStatement.setRowPrefetch, getDefaultRowPrefetch

setEndToEndMetrics

public void setEndToEndMetrics(java.lang.String[] metrics,
                               short sequenceNumber)
                        throws java.sql.SQLException
Description copied from interface: OracleConnection
Sets the values of the end-to-end tracing metrics. The indices for the array are the END_TO_END_XXX_INDEX values defined in this class. The values set by this method are overridden by any values set via DMS if DMS is in use.
Specified by:
setEndToEndMetrics in interface OracleConnection
Parameters:
metrics - String[] containing the metric values.
sequenceNumber - the sequence number for the context id
Throws:
java.sql.SQLException - if an error occurs
See Also:
getEndToEndMetrics

setExplicitCachingEnabled

public void setExplicitCachingEnabled(boolean cache)
                               throws java.sql.SQLException
Description copied from interface: OracleConnection
setExplicitCachingEnabled Enables or disables the explicit cache. Note that this is independent of the cache size, set with setStatmentCacheSize().
Specified by:
setExplicitCachingEnabled in interface OracleConnection
Parameters:
cache - If true, then explicit caching will be enabled. If false, then any existing statements will be purged and the explicit cache will be disabled.
Throws:
java.sql.SQLException - if called on a logical connection.

setImplicitCachingEnabled

public void setImplicitCachingEnabled(boolean cache)
                               throws java.sql.SQLException
Description copied from interface: OracleConnection
setImplicitCachingEnabled Enables or disables the implicit cache. Note that this is independent of the cache size, set with setStatmentCacheSize().
Specified by:
setImplicitCachingEnabled in interface OracleConnection
Parameters:
cache - If true, then implicit caching will be enabled. If false, then any existing statements will be purged and the implicit cache will be disabled.
Throws:
java.sql.SQLException - if called on a logical connection.

setIncludeSynonyms

public void setIncludeSynonyms(boolean synonyms)
Description copied from interface: OracleConnection
Turns on or off retrieval of synonym information in DatabaseMetaData. getColumns.

Similar to setRemarksReporting, getColumns performs extremely slow if information about synonyms has to be included, because it neccessitates an outer join so, by default, the JDBC driver will not report information about synonyms.

You can get synonym information by passing true to this method, and turn it off by passing false. You can also control this behavior by passing a property named "includeSynonyms" as "true" to DriverManager.getConnection.

Specified by:
setIncludeSynonyms in interface OracleConnection
Parameters:
synonyms - true if you want to retrieve synonym information in DatabaseMetaData.getColumns and false otherwise.
See Also:
getIncludeSynonyms

setRemarksReporting

public void setRemarksReporting(boolean reportRemarks)
Description copied from interface: OracleConnection
Turns on or off the reporting of the REMARKS columns by the getTables and getColumns calls of the DatabaseMetaData interface.

The DatabaseMetaData calls getTables and getColumns are extremely slow if the REMARKS column has to be reported as this necessitates an expensive outer join so by default the JDBC driver does not report the REMARKS columns.

You can turn the reporting of REMARKS on by passing a true argument to this method. You turn it back off by passing a false argument.

Example where conn is your connection object:
((OracleConnection)conn).setRemarksReporting(true);

You can also control the reporting of REMARKS by passing a property named remarksReporting as true to the DriverManager.getConnection call.

Specified by:
setRemarksReporting in interface OracleConnection
Parameters:
reportRemarks - true if you want to turn on the reporting of the REMARKS columns and false otherwise.
See Also:
getRemarksReporting

setRestrictGetTables

public void setRestrictGetTables(boolean restrict)
Description copied from interface: OracleConnection
Turns on or off the restriction of the returned data in DatabaseMetaData.getTables.

DatabaseMetaData.getTables will return information about all accessible tables, views, and synonyms. There are two issues relating to synonyms which can affect the quality of the returned data:

  1. Public synonyms can exist for tables to which you don't have access. Although the synonym itself is viewable, the underlying table is not.
  2. Synonyms can exist for non-table objects, such as procedures, sequences, Java classes, etc.
As a result of the above issues, getTables can return rows containing objects that are not describable with getColumns, either because they are not accessible (issue 1) or because they are not tables or views (issue 2).

To remedy this, you can restrict the results of getTables to only those tables and views to which you have access. This is done by either passing true to this method, or by passing the restrictGetTables property as true to the DriverManager.getConnection call. The default behavior is to return information about all synonyms, including those which do not point to accessible tables or views.

Note that getTables can return more than one row for the same object, one for the object itself, and additional rows for any synonyms defined for that object. This is the case regardless of the setting for restrictGetTables.

The following code turns on the restriction:
((OracleConnection)conn).setRestrictGetTables(true);

Specified by:
setRestrictGetTables in interface OracleConnection
Parameters:
restrict - true to turn on the restriction and false otherwise.
See Also:
getRestrictGetTables

setStmtCacheSize

public void setStmtCacheSize(int size)
                      throws java.sql.SQLException
Specified by:
setStmtCacheSize in interface OracleConnection
Throws:
java.sql.SQLException

setStatementCacheSize

public void setStatementCacheSize(int size)
                           throws java.sql.SQLException
Description copied from interface: OracleConnection
setStatementCacheSize Specifies the size of the size of the application cache (which will be used by both implicit and explicit caching).
Specified by:
setStatementCacheSize in interface OracleConnection
Parameters:
size - Requested size of the cache. If the existing cache size is less than size, statements will be purged to reduce the size.
Throws:
java.sql.SQLException - if size < 0, or if called on a logical connection.

setStmtCacheSize

public void setStmtCacheSize(int size,
                             boolean clearMetaData)
                      throws java.sql.SQLException
Specified by:
setStmtCacheSize in interface OracleConnection
Throws:
java.sql.SQLException

setUsingXAFlag

public void setUsingXAFlag(boolean value)
Description copied from interface: OracleConnection
When using distributed transactions with XA, you can set the value of the UsingXA flag.

XA is a general standard (not specific to Java) for distributed transactions. You should use this method only when using XA.

By default, when using distributed transactions with XA, the driver will set the UsingXA flag to true and exceptions will be raised when you want to do anything with your logical connection that might require a transaction. Otherwise the flag UsingXA is always false.

If you are actually using distributed transactions with XA and you dislike the default behavior, you can set the flag back to false.

Specified by:
setUsingXAFlag in interface OracleConnection
Parameters:
value - the value of the UsingXA flag
See Also:
getUsingXAFlag

setXAErrorFlag

public void setXAErrorFlag(boolean value)
Description copied from interface: OracleConnection
Sets the value of the XAError flag which is used with distributed transactions. When coexisting with an XA library, you can set the XAError flag to true and the driver will then raise an exception when doing anything that might require a transaction.
Specified by:
setXAErrorFlag in interface OracleConnection
Parameters:
value - the value of the XAError flag
See Also:
getXAErrorFlag

shutdown

public void shutdown(OracleConnection.DatabaseShutdownMode mode)
              throws java.sql.SQLException
Description copied from interface: OracleConnection
Shuts the database server down. This method requires to be connected as either SYSOPER or SYSDBA.
Specified by:
shutdown in interface OracleConnection
Parameters:
mode - can be either
  • OracleConnection.DatabaseShutdownMode.CONNECT
  • OracleConnection.DatabaseShutdownMode.TRANSACTIONAL
  • OracleConnection.DatabaseShutdownMode.TRANSACTIONAL_LOCAL
  • OracleConnection.DatabaseShutdownMode.IMMEDIATE
  • OracleConnection.DatabaseShutdownMode.ABORT
  • OracleConnection.DatabaseShutdownMode.FINAL
Throws:
java.sql.SQLException

startup

public void startup(java.lang.String startup_str,
                    int mode)
             throws java.sql.SQLException
Description copied from interface: OracleConnection
Not implemented
Specified by:
startup in interface OracleConnection
Throws:
java.sql.SQLException

startup

public void startup(OracleConnection.DatabaseStartupMode mode)
             throws java.sql.SQLException
Description copied from interface: OracleConnection
Starts the database server up. This method requires to be connected as either SYSOPER or SYSDBA in the PRELIM_AUTH mode which is the only mode permietted when the database is down (see the connection property CONNECTION_PROPERTY_PRELIM_AUTH).
Specified by:
startup in interface OracleConnection
Parameters:
mode - can be either
  • OracleConnection.DatabaseStartupMode.NO_RESTRICTION
  • OracleConnection.DatabaseStartupMode.FORCE
  • OracleConnection.DatabaseStartupMode.RESTRICT
Throws:
java.sql.SQLException

prepareStatementWithKey

public java.sql.PreparedStatement prepareStatementWithKey(java.lang.String key)
                                                   throws java.sql.SQLException
Specified by:
prepareStatementWithKey in interface OracleConnection
Parameters:
key - the key with which it was closed
Returns:
a OraclePreparedStatement object
Throws:
java.sql.SQLException - if a database access error occurs

prepareCallWithKey

public java.sql.CallableStatement prepareCallWithKey(java.lang.String key)
                                              throws java.sql.SQLException
Specified by:
prepareCallWithKey in interface OracleConnection
Parameters:
key - the key with which it was closed
Returns:
a oracle.jdbc.driver.CallableStatement object
Throws:
java.sql.SQLException - if a database access error occurs

setCreateStatementAsRefCursor

public void setCreateStatementAsRefCursor(boolean value)
Description copied from interface: OracleConnection
When this is set to true, any new statements created from this connection will be created as a REF CURSOR. Only resultsets obtained from statements that are created as REF CURSORS can be returned from a Java Stored Procedure. This feature is supported by the server-side internal driver only, and is no-op in all other JDBC drivers.

Default value is false.

To use the setCreateStatementAsRefCursor entrypoint you have to cast the Connection object to the type oracle.jdbc.OracleConnection.

Specified by:
setCreateStatementAsRefCursor in interface OracleConnection
Parameters:
value - true if new statements should be created as REF CURSORS, false otherwise
See Also:
getCreateStatementAsRefCursor

getCreateStatementAsRefCursor

public boolean getCreateStatementAsRefCursor()
Description copied from interface: OracleConnection
Retrieves the current setting of the createStatementAsRefCursor flag which you can set with the setCreateStatementAsRefCursor method.

To use the getCreateStatementAsRefCursor entrypoint you have to cast the Connection object to the type oracle.jdbc.OracleConnection.

Specified by:
getCreateStatementAsRefCursor in interface OracleConnection
Returns:
the current setting of the createStatementAsRefCursor flag
See Also:
setCreateStatementAsRefCursor

setSessionTimeZone

public void setSessionTimeZone(java.lang.String regionName)
                        throws java.sql.SQLException
Description copied from interface: OracleConnection
Set the session time zone.

This method is used to set the session time zone. This method must be invoked before accessing any TIMESTAMP WITH LOCAL TIME ZONE data. Upon invocation of this method, the Jdbc driver sets the session timezone of the connection and saves the session timezone so that any TSLTZ data accessed via Jdbc are adjusted using the session timezone.

Specified by:
setSessionTimeZone in interface OracleConnection
Parameters:
regionName - Oracle session time zone region name.
Throws:
java.sql.SQLException - if an error occurred.

getSessionTimeZone

public java.lang.String getSessionTimeZone()
Description copied from interface: OracleConnection
Obtain Oracle session time zone region name.
Specified by:
getSessionTimeZone in interface OracleConnection
Returns:
Oracle session time zone region name.

getSessionTimeZoneOffset

public java.lang.String getSessionTimeZoneOffset()
                                          throws java.sql.SQLException
Description copied from interface: OracleConnection
Obtain the time zone offset in hours of the current database session. The result will always be accurate. In other words, you can execute "ALTER SESSION SET TIME_ZONE ..." and then call this method, it will return the new value.

The value returned by this method is that same as the result of "SELECT SESSIONTIMEZONE FROM DUAL;". The drivers may use some performance optimization to not use a roundtrip to the server so it is always preferrable to use this method.

Specified by:
getSessionTimeZoneOffset in interface OracleConnection
Returns:
Oracle session time zone in hours. For example "-7:00" or "0:00"
Throws:
java.sql.SQLException

_getPC

public java.sql.Connection _getPC()
Description copied from interface: OracleConnection
Return the underlying physical connection if this is a logical connection. Returns null otherwise.
Specified by:
_getPC in interface OracleConnection
Returns:
Connection object if its a logical handle otherwise returns null

isLogicalConnection

public boolean isLogicalConnection()
Description copied from interface: OracleConnection
Method that returns a boolean indicating whether its a logical connection or not.
Specified by:
isLogicalConnection in interface OracleConnection
Returns:
boolean true if this is a logical connection

registerTAFCallback

public void registerTAFCallback(OracleOCIFailover cbk,
                                java.lang.Object obj)
                         throws java.sql.SQLException
Description copied from interface: OracleConnection
Register an application TAF Callback instance that will be called when an application failover occurs. The TAF feature is only available in the Jdbc OCI driver.
Specified by:
registerTAFCallback in interface OracleConnection
Parameters:
cbk - Callback instance.
obj - Context object in which any client's state can be stored and provided when the callback method is invoked.
Throws:
java.sql.SQLException - if this method is invoked in drivers other than the Jdbc OCI driver.

getProperties

public java.util.Properties getProperties()
Description copied from interface: OracleConnection
Determines the connection properties.
Specified by:
getProperties in interface OracleConnection
Returns:

close

public void close(java.util.Properties connAttr)
           throws java.sql.SQLException
Description copied from interface: OracleConnection
Closes the given Logical connection, and returns the underlying PooledConnection to the implicit connection cache. The connection Attributes is set on the PooledConnection. If the connection Attributes passed is null, then a null value is set on the PooledConnection as well. When called on a physical connection, the connection Attributes passed in has no effect.
Specified by:
close in interface OracleConnection
Parameters:
connAttr - the connection Attributes to be applied
Throws:
java.sql.SQLException - if a database access error occurs

close

public void close(int opt)
           throws java.sql.SQLException
Description copied from interface: OracleConnection
If opt is OracleConnection.INVALID_CONNECTION : Closes the given Logical connection, as well the underlying PooledConnection without returning the connection to the cache when called with the parameter INVALID_CONNECTION. If this API is called on a physical connection, the supplied parameter has no effect.

If opt is OracleConnection.PROXY_SESSION : Closes the proxy session (opened with openProxySession()).
Specified by:
close in interface OracleConnection
Parameters:
opt - set to INVALID_CONNECTION to close the PooledConnection
Throws:
java.sql.SQLException - if a database access error occurs

applyConnectionAttributes

public void applyConnectionAttributes(java.util.Properties connAttr)
                               throws java.sql.SQLException
Description copied from interface: OracleConnection
Applies the connection Attributes provided on the underlying PooledConnection. The connection Attributes set via the close API overrides the value set by this API.
Specified by:
applyConnectionAttributes in interface OracleConnection
Parameters:
connAttr - the connection Attributes to be applied
Throws:
java.sql.SQLException - if a database access error occurs

getConnectionAttributes

public java.util.Properties getConnectionAttributes()
                                             throws java.sql.SQLException
Description copied from interface: OracleConnection
Returns the connection Attributes set on the underlying PooledConnection. This API returns null when called on a physical connection.
Specified by:
getConnectionAttributes in interface OracleConnection
Returns:
Throws:
java.sql.SQLException - if a database access error occurs

getUnMatchedConnectionAttributes

public java.util.Properties getUnMatchedConnectionAttributes()
                                                      throws java.sql.SQLException
Description copied from interface: OracleConnection
Returns the unmatched connection Attributes from the underlying PooledConnection. These are essentially the PooledConnection Attributes that did not match the ones from the connection request. This API returns null when called on a physical connection.
Specified by:
getUnMatchedConnectionAttributes in interface OracleConnection
Throws:
java.sql.SQLException - if a database access error occurs

registerConnectionCacheCallback

public void registerConnectionCacheCallback(OracleConnectionCacheCallback occc,
                                            java.lang.Object userObj,
                                            int cbkFlag)
                                     throws java.sql.SQLException
Description copied from interface: OracleConnection
Registers the connection cache callback on the logical connection This is used in conjunction with the Implicit Connection Cache Properties.
Specified by:
registerConnectionCacheCallback in interface OracleConnection
Parameters:
occc - Implementation of the OracleConnectionCacheCallback Interface
userObj - User private object to be passed when invoking callbacks
cbkFlag - Indicates which callback method to invoke. Supported values are: ABANDONED_CONNECTION_CALLBACK RELEASE_CONNECTION_CALLBACK ALL_CONNECTION_CALLBACKS
Throws:
java.sql.SQLException - if a database access error occurs

setConnectionReleasePriority

public void setConnectionReleasePriority(int priority)
                                  throws java.sql.SQLException
Description copied from interface: OracleConnection
Sets connection release priority. Works in conjunction with the Connection Cache Callback method RELEASE_CONNECTION_CALLBACK Suported release priorities are: CONNECTION_RELEASE_LOCKED CONNECTION_RELEASE_LOW CONNECTION_RELEASE_HIGH
Specified by:
setConnectionReleasePriority in interface OracleConnection
Parameters:
priority - one of the above release priority
Throws:
java.sql.SQLException - if a database access error occurs

getConnectionReleasePriority

public int getConnectionReleasePriority()
                                 throws java.sql.SQLException
Description copied from interface: OracleConnection
Returns the release priority set on the connection
Specified by:
getConnectionReleasePriority in interface OracleConnection
Throws:
java.sql.SQLException - if a database access error occurs

setPlsqlWarnings

public void setPlsqlWarnings(java.lang.String setting)
                      throws java.sql.SQLException
Description copied from interface: OracleConnection
Enable/Disable PLSQL Compiler Warnings
Specified by:
setPlsqlWarnings in interface OracleConnection
Parameters:
setting - Setting specified for ALTER SESSION SET PLSQL_WARNINGS. Sample values are: "'ENABLE:ALL'", "'DISABLE:ALL'", "'ENALBLE:INFORMATIONAL'", etc. Please refer to the SQL reference of ALTER SESSION SET PLSQL_WARNINGS for more information. If the setting is "'DISABLE:ALL'", jdbc drivers turn off PLSQL Compiler Warnings. Note: the quotes(') in the setting String are necessary.
Throws:
java.sql.SQLException - if a database access error occurs

setHoldability

public void setHoldability(int holdability)
                    throws java.sql.SQLException
Specified by:
setHoldability in interface java.sql.Connection
Throws:
java.sql.SQLException

getHoldability

public int getHoldability()
                   throws java.sql.SQLException
Specified by:
getHoldability in interface java.sql.Connection
Throws:
java.sql.SQLException

createStatement

public java.sql.Statement createStatement(int resultSetType,
                                          int resultSetConcurrency,
                                          int resultSetHoldability)
                                   throws java.sql.SQLException
Specified by:
createStatement in interface java.sql.Connection
Throws:
java.sql.SQLException

prepareStatement

public java.sql.PreparedStatement prepareStatement(java.lang.String sql,
                                                   int resultSetType,
                                                   int resultSetConcurrency,
                                                   int resultSetHoldability)
                                            throws java.sql.SQLException
Specified by:
prepareStatement in interface java.sql.Connection
Throws:
java.sql.SQLException

prepareCall

public java.sql.CallableStatement prepareCall(java.lang.String sql,
                                              int resultSetType,
                                              int resultSetConcurrency,
                                              int resultSetHoldability)
                                       throws java.sql.SQLException
Specified by:
prepareCall in interface java.sql.Connection
Throws:
java.sql.SQLException

setSavepoint

public java.sql.Savepoint setSavepoint()
                                throws java.sql.SQLException
Specified by:
setSavepoint in interface java.sql.Connection
Throws:
java.sql.SQLException

setSavepoint

public java.sql.Savepoint setSavepoint(java.lang.String name)
                                throws java.sql.SQLException
Specified by:
setSavepoint in interface java.sql.Connection
Throws:
java.sql.SQLException

rollback

public void rollback(java.sql.Savepoint savepoint)
              throws java.sql.SQLException
Specified by:
rollback in interface java.sql.Connection
Throws:
java.sql.SQLException

releaseSavepoint

public void releaseSavepoint(java.sql.Savepoint savepoint)
                      throws java.sql.SQLException
Specified by:
releaseSavepoint in interface java.sql.Connection
Throws:
java.sql.SQLException

prepareStatement

public java.sql.PreparedStatement prepareStatement(java.lang.String sql,
                                                   int autoGeneratedKeys)
                                            throws java.sql.SQLException
Specified by:
prepareStatement in interface java.sql.Connection
Throws:
java.sql.SQLException

prepareStatement

public java.sql.PreparedStatement prepareStatement(java.lang.String sql,
                                                   int[] columnIndexes)
                                            throws java.sql.SQLException
Specified by:
prepareStatement in interface java.sql.Connection
Throws:
java.sql.SQLException

prepareStatement

public java.sql.PreparedStatement prepareStatement(java.lang.String sql,
                                                   java.lang.String[] columnNames)
                                            throws java.sql.SQLException
Specified by:
prepareStatement in interface java.sql.Connection
Throws:
java.sql.SQLException

createARRAY

public ARRAY createARRAY(java.lang.String typeName,
                         java.lang.Object elements)
                  throws java.sql.SQLException
Creates an ARRAY object with the given type name and elements.
Specified by:
createARRAY in interface OracleConnection
Parameters:
typeName - the name of the SQL type of the created object
elements - the elements of the created object
Returns:
an ARRAY
Throws:
java.sql.SQLException - if a database error occurs
Since:
11R1

createOracleArray

public java.sql.Array createOracleArray(java.lang.String arrayTypeName,
                                        java.lang.Object elements)
                                 throws java.sql.SQLException
Creates an Array object with the given type name and elements. The standard createArrayOf accepts the element type name. This method accepts the type of the array itself. Oracle does not support anonymous array types and so does not support the standard createArrayOf method.
Specified by:
createOracleArray in interface OracleConnection
Parameters:
arrayTypeName - the name of the SQL type of the created object
elements - the elements of the created object
Returns:
an ARRAY
Throws:
java.sql.SQLException - if a database error occurs
Since:
11.2.0.5.0

createBINARY_DOUBLE

public BINARY_DOUBLE createBINARY_DOUBLE(double value)
                                  throws java.sql.SQLException
Creates a BINARY_DOUBLE that has the given value.
Specified by:
createBINARY_DOUBLE in interface OracleConnection
Parameters:
value - the value that the new object should represent
Returns:
a new BINARY_DOUBLE
Throws:
java.sql.SQLException - if a database error occurs
Since:
11R1

createBINARY_FLOAT

public BINARY_FLOAT createBINARY_FLOAT(float value)
                                throws java.sql.SQLException
Creates a BINARY_FLOAT that has the given value.
Specified by:
createBINARY_FLOAT in interface OracleConnection
Parameters:
value - the value that the new object should represent
Returns:
a new BINARY_FLOAT
Throws:
java.sql.SQLException - if a database error occurs
Since:
11R1

createDATE

public DATE createDATE(java.sql.Date value)
                throws java.sql.SQLException
Creates a DATE that has the given value.
Specified by:
createDATE in interface OracleConnection
Parameters:
value - the value that the new object should repreesnt
Returns:
a new DATE
Throws:
java.sql.SQLException - if a database error occurs
Since:
11R1

createDATE

public DATE createDATE(java.sql.Time value)
                throws java.sql.SQLException
Creates a DATE that has the given value.
Specified by:
createDATE in interface OracleConnection
Parameters:
value - the value that the new object should repreesnt
Returns:
a new DATE
Throws:
java.sql.SQLException - if a database error occurs
Since:
11R1

createDATE

public DATE createDATE(java.sql.Timestamp value)
                throws java.sql.SQLException
Creates a DATE that has the given value.
Specified by:
createDATE in interface OracleConnection
Parameters:
value - the value that the new object should repreesnt
Returns:
a new DATE
Throws:
java.sql.SQLException - if a database error occurs
Since:
11R1

createDATE

public DATE createDATE(java.sql.Date value,
                       java.util.Calendar cal)
                throws java.sql.SQLException
Creates a DATE that has the given value. The value is interpreted as being in the time zone represented by cal.
Specified by:
createDATE in interface OracleConnection
Parameters:
value - the value that the new object should repreesnt
cal - the timezone in which the value is interpreted
Returns:
a new DATE
Throws:
java.sql.SQLException - if a database error occurs
Since:
11R1

createDATE

public DATE createDATE(java.sql.Time value,
                       java.util.Calendar cal)
                throws java.sql.SQLException
Creates a DATE that has the given value. The value is interpreted as being in the time zone represented by cal.
Specified by:
createDATE in interface OracleConnection
Parameters:
value - the value that the new object should repreesnt
cal - the timezone in which the value is interpreted
Returns:
a new DATE
Throws:
java.sql.SQLException - if a database error occurs
Since:
11R1

createDATE

public DATE createDATE(java.sql.Timestamp value,
                       java.util.Calendar cal)
                throws java.sql.SQLException
Creates a DATE that has the given value. The value is interpreted as being in the time zone represented by cal.
Specified by:
createDATE in interface OracleConnection
Parameters:
value - the value that the new object should repreesnt
cal - the timezone in which the value is interpreted
Returns:
a new DATE
Throws:
java.sql.SQLException - if a database error occurs
Since:
11R1

createDATE

public DATE createDATE(java.lang.String value)
                throws java.sql.SQLException
Creates a DATE that has the given value.
Specified by:
createDATE in interface OracleConnection
Parameters:
value - the value that the new object should repreesnt
Returns:
a new DATE
Throws:
java.sql.SQLException - if a database error occurs
Since:
11R1

createINTERVALDS

public INTERVALDS createINTERVALDS(java.lang.String value)
                            throws java.sql.SQLException
Creates an INTERVALDS that has the given value.
Specified by:
createINTERVALDS in interface OracleConnection
Parameters:
value - the value that the new object shoud represent
Returns:
a new INTERVALDS
Throws:
java.sql.SQLException - if a database error occurs
Since:
11R1

createINTERVALYM

public INTERVALYM createINTERVALYM(java.lang.String value)
                            throws java.sql.SQLException
Creates an INTERVALYM that has the given value.
Specified by:
createINTERVALYM in interface OracleConnection
Parameters:
value - the value that the new object shoud represent
Returns:
a new INTERVALYM
Throws:
java.sql.SQLException - if a database error occurs
Since:
11R1

createNUMBER

public NUMBER createNUMBER(boolean value)
                    throws java.sql.SQLException
Creates a new NUMBER that has the given value.
Specified by:
createNUMBER in interface OracleConnection
Parameters:
value - the value that the new object should represent
Returns:
a new NUMBER
Throws:
java.sql.SQLException - if a database error occurs
Since:
11R1

createNUMBER

public NUMBER createNUMBER(byte value)
                    throws java.sql.SQLException
Creates a new NUMBER that has the given value.
Specified by:
createNUMBER in interface OracleConnection
Parameters:
value - the value that the new object should represent
Returns:
a new NUMBER
Throws:
java.sql.SQLException - if a database error occurs
Since:
11R1

createNUMBER

public NUMBER createNUMBER(short value)
                    throws java.sql.SQLException
Creates a new NUMBER that has the given value.
Specified by:
createNUMBER in interface OracleConnection
Parameters:
value - the value that the new object should represent
Returns:
a new NUMBER
Throws:
java.sql.SQLException - if a database error occurs
Since:
11R1

createNUMBER

public NUMBER createNUMBER(int value)
                    throws java.sql.SQLException
Creates a new NUMBER that has the given value.
Specified by:
createNUMBER in interface OracleConnection
Parameters:
value - the value that the new object should represent
Returns:
a new NUMBER
Throws:
java.sql.SQLException - if a database error occurs
Since:
11R1

createNUMBER

public NUMBER createNUMBER(long value)
                    throws java.sql.SQLException
Creates a new NUMBER that has the given value.
Specified by:
createNUMBER in interface OracleConnection
Parameters:
value - the value that the new object should represent
Returns:
a new NUMBER
Throws:
java.sql.SQLException - if a database error occurs
Since:
11R1

createNUMBER

public NUMBER createNUMBER(float value)
                    throws java.sql.SQLException
Creates a new NUMBER that has the given value.
Specified by:
createNUMBER in interface OracleConnection
Parameters:
value - the value that the new object should represent
Returns:
a new NUMBER
Throws:
java.sql.SQLException - if a database error occurs
Since:
11R1

createNUMBER

public NUMBER createNUMBER(double value)
                    throws java.sql.SQLException
Creates a new NUMBER that has the given value.
Specified by:
createNUMBER in interface OracleConnection
Parameters:
value - the value that the new object should represent
Returns:
a new NUMBER
Throws:
java.sql.SQLException - if a database error occurs
Since:
11R1

createNUMBER

public NUMBER createNUMBER(java.math.BigDecimal value)
                    throws java.sql.SQLException
Creates a new NUMBER that has the given value.
Specified by:
createNUMBER in interface OracleConnection
Parameters:
value - the value that the new object should represent
Returns:
a new NUMBER
Throws:
java.sql.SQLException - if a database error occurs
Since:
11R1

createNUMBER

public NUMBER createNUMBER(java.math.BigInteger value)
                    throws java.sql.SQLException
Creates a new NUMBER that has the given value.
Specified by:
createNUMBER in interface OracleConnection
Parameters:
value - the value that the new object should represent
Returns:
a new NUMBER
Throws:
java.sql.SQLException - if a database error occurs
Since:
11R1

createNUMBER

public NUMBER createNUMBER(java.lang.String value,
                           int scale)
                    throws java.sql.SQLException
Creates a new NUMBER that has the given value and scale.
Specified by:
createNUMBER in interface OracleConnection
Parameters:
value - the value that the new object should represent
scale - the scale of the new object
Returns:
a new NUMBER
Throws:
java.sql.SQLException - if a database error occurs
Since:
11R1

createTIMESTAMP

public TIMESTAMP createTIMESTAMP(java.sql.Date value)
                          throws java.sql.SQLException
Creates a new TIMESTAMP with the given value.
Specified by:
createTIMESTAMP in interface OracleConnection
Parameters:
value - the value that the new object should represent
Returns:
a new TIMESTAMP
Throws:
java.sql.SQLException - if a database error occurs
Since:
11R1

createTIMESTAMP

public TIMESTAMP createTIMESTAMP(DATE value)
                          throws java.sql.SQLException
Creates a new TIMESTAMP with the given value.
Specified by:
createTIMESTAMP in interface OracleConnection
Parameters:
value - the value that the new object should represent
Returns:
a new TIMESTAMP
Throws:
java.sql.SQLException - if a database error occurs
Since:
11R1

createTIMESTAMP

public TIMESTAMP createTIMESTAMP(java.sql.Time value)
                          throws java.sql.SQLException
Creates a new TIMESTAMP with the given value.
Specified by:
createTIMESTAMP in interface OracleConnection
Parameters:
value - the value that the new object should represent
Returns:
a new TIMESTAMP
Throws:
java.sql.SQLException - if a database error occurs
Since:
11R1

createTIMESTAMP

public TIMESTAMP createTIMESTAMP(java.sql.Timestamp value)
                          throws java.sql.SQLException
Creates a new TIMESTAMP with the given value.
Specified by:
createTIMESTAMP in interface OracleConnection
Parameters:
value - the value that the new object should represent
Returns:
a new TIMESTAMP
Throws:
java.sql.SQLException - if a database error occurs
Since:
11R1

createTIMESTAMP

public TIMESTAMP createTIMESTAMP(java.lang.String value)
                          throws java.sql.SQLException
Creates a new TIMESTAMP with the given value.
Specified by:
createTIMESTAMP in interface OracleConnection
Parameters:
value - the value that the new object should represent
Returns:
a new TIMESTAMP
Throws:
java.sql.SQLException - if a database error occurs
Since:
11R1

createTIMESTAMPTZ

public TIMESTAMPTZ createTIMESTAMPTZ(java.sql.Date value)
                              throws java.sql.SQLException
Creates a new TIMESTAMPTZ with the given value.
Specified by:
createTIMESTAMPTZ in interface OracleConnection
Parameters:
value - the value that the new object should represent
Returns:
a new TIMESTAMPTZ
Throws:
java.sql.SQLException - if a database error occurs
Since:
11R1

createTIMESTAMPTZ

public TIMESTAMPTZ createTIMESTAMPTZ(java.sql.Date value,
                                     java.util.Calendar cal)
                              throws java.sql.SQLException
Creates a new TIMESTAMPTZ with the given value. The value is interpreted in the time zone of the calendar.
Specified by:
createTIMESTAMPTZ in interface OracleConnection
Parameters:
value - the value that the new object should represent
cal - the timezone of the value
Returns:
a new TIMESTAMPTZ
Throws:
java.sql.SQLException - if a database error occurs
Since:
11R1

createTIMESTAMPTZ

public TIMESTAMPTZ createTIMESTAMPTZ(java.sql.Time value)
                              throws java.sql.SQLException
Creates a new TIMESTAMPTZ with the given value.
Specified by:
createTIMESTAMPTZ in interface OracleConnection
Parameters:
value - the value that the new object should represent
Returns:
a new TIMESTAMPTZ
Throws:
java.sql.SQLException - if a database error occurs
Since:
11R1

createTIMESTAMPTZ

public TIMESTAMPTZ createTIMESTAMPTZ(java.sql.Time value,
                                     java.util.Calendar cal)
                              throws java.sql.SQLException
Creates a new TIMESTAMPTZ with the given value. The value is interpreted in the time zone of the calendar.
Specified by:
createTIMESTAMPTZ in interface OracleConnection
Parameters:
value - the value that the new object should represent
cal - the timezone of the value
Returns:
a new TIMESTAMPTZ
Throws:
java.sql.SQLException - if a database error occurs
Since:
11R1

createTIMESTAMPTZ

public TIMESTAMPTZ createTIMESTAMPTZ(java.sql.Timestamp value)
                              throws java.sql.SQLException
Creates a new TIMESTAMPTZ with the given value.
Specified by:
createTIMESTAMPTZ in interface OracleConnection
Parameters:
value - the value that the new object should represent
Returns:
a new TIMESTAMPTZ
Throws:
java.sql.SQLException - if a database error occurs
Since:
11R1

createTIMESTAMPTZ

public TIMESTAMPTZ createTIMESTAMPTZ(java.sql.Timestamp value,
                                     java.util.Calendar cal)
                              throws java.sql.SQLException
Creates a new TIMESTAMPTZ with the given value. The value is interpreted in the time zone of the calendar.
Specified by:
createTIMESTAMPTZ in interface OracleConnection
Parameters:
value - the value that the new object should represent
cal - the timezone of the value
Returns:
a new TIMESTAMPTZ
Throws:
java.sql.SQLException - if a database error occurs
Since:
11R1

createTIMESTAMPTZ

public TIMESTAMPTZ createTIMESTAMPTZ(java.lang.String value)
                              throws java.sql.SQLException
Creates a new TIMESTAMPTZ with the given value.
Specified by:
createTIMESTAMPTZ in interface OracleConnection
Parameters:
value - the value that the new object should represent
Returns:
a new TIMESTAMPTZ
Throws:
java.sql.SQLException - if a database error occurs
Since:
11R1

createTIMESTAMPTZ

public TIMESTAMPTZ createTIMESTAMPTZ(java.lang.String value,
                                     java.util.Calendar cal)
                              throws java.sql.SQLException
Creates a new TIMESTAMPTZ with the given value. The value is interpreted in the time zone of the calendar.
Specified by:
createTIMESTAMPTZ in interface OracleConnection
Parameters:
value - the value that the new object should represent
cal - the timezone of the value
Returns:
a new TIMESTAMPTZ
Throws:
java.sql.SQLException - if a database error occurs
Since:
11R1

createTIMESTAMPTZ

public TIMESTAMPTZ createTIMESTAMPTZ(DATE value)
                              throws java.sql.SQLException
Specified by:
createTIMESTAMPTZ in interface OracleConnection
Throws:
java.sql.SQLException - if a database error occurs
Since:
11R1

createTIMESTAMPLTZ

public TIMESTAMPLTZ createTIMESTAMPLTZ(java.sql.Date value,
                                       java.util.Calendar cal)
                                throws java.sql.SQLException
Creates a new TIMESTAMPLTZ with the given value. The value is interpreted in the time zone of the calendar.
Specified by:
createTIMESTAMPLTZ in interface OracleConnection
Parameters:
value - the value that the new object should represent
cal - the timezone of the value
Returns:
a new TIMESTAMPLTZ
Throws:
java.sql.SQLException - if a database error occurs
Since:
11R1

createTIMESTAMPLTZ

public TIMESTAMPLTZ createTIMESTAMPLTZ(java.sql.Time value,
                                       java.util.Calendar cal)
                                throws java.sql.SQLException
Creates a new TIMESTAMPLTZ with the given value. The value is interpreted in the time zone of the calendar.
Specified by:
createTIMESTAMPLTZ in interface OracleConnection
Parameters:
value - the value that the new object should represent
cal - the timezone of the value
Returns:
a new TIMESTAMPLTZ
Throws:
java.sql.SQLException - if a database error occurs
Since:
11R1

createTIMESTAMPLTZ

public TIMESTAMPLTZ createTIMESTAMPLTZ(java.sql.Timestamp value,
                                       java.util.Calendar cal)
                                throws java.sql.SQLException
Creates a new TIMESTAMPLTZ with the given value. The value is interpreted in the time zone of the calendar.
Specified by:
createTIMESTAMPLTZ in interface OracleConnection
Parameters:
value - the value that the new object should represent
cal - the timezone of the value
Returns:
a new TIMESTAMPLTZ
Throws:
java.sql.SQLException - if a database error occurs
Since:
11R1

createTIMESTAMPLTZ

public TIMESTAMPLTZ createTIMESTAMPLTZ(java.lang.String value,
                                       java.util.Calendar cal)
                                throws java.sql.SQLException
Creates a new TIMESTAMPLTZ with the given value. The value is interpreted in the time zone of the calendar.
Specified by:
createTIMESTAMPLTZ in interface OracleConnection
Parameters:
value - the value that the new object should represent
cal - the timezone of the value
Returns:
a new TIMESTAMPLTZ
Throws:
java.sql.SQLException - if a database error occurs
Since:
11R1

createTIMESTAMPLTZ

public TIMESTAMPLTZ createTIMESTAMPLTZ(DATE value,
                                       java.util.Calendar cal)
                                throws java.sql.SQLException
Creates a new TIMESTAMPLTZ with the given value. The value is interpreted in the time zone of the calendar.
Specified by:
createTIMESTAMPLTZ in interface OracleConnection
Parameters:
value - the value that the new object should represent
cal - the timezone of the value
Returns:
a new TIMESTAMPLTZ
Throws:
java.sql.SQLException - if a database error occurs
Since:
11R1

registerDatabaseChangeNotification

public DatabaseChangeRegistration registerDatabaseChangeNotification(java.util.Properties options)
                                                              throws java.sql.SQLException
Description copied from interface: OracleConnection
Creates a new database change registration.

This method creates a new database change registration in the database server with the given options. It also opens a listening socket which will be used by the database to send notifications. Note that if there already is a listening socket (created by a different registration), then it will be used by this registration as well.

This method returns a DatabaseChangeRegistration object that can then be used to associate a statement with this registration.

The registration will continue to live after this connection is closed. You need to explicitly unregister it to destroy it in the server and release the resources in the driver.

This method uses one roundtrip.

Specified by:
registerDatabaseChangeNotification in interface OracleConnection
Parameters:
options - Possible options are ([] means default):
  • OracleConnection.NTF_QOS_RELIABLE: "true"/["false"]. Set this option to "true" to make the notifications persistent which comes at a performance cost.
  • OracleConnection.NTF_QOS_PURGE_ON_NTFN: "true"/["false"]. Set this option to "true" and the registration will be expunged on the first notification event.
  • OracleConnection.NTF_TIMEOUT: value in seconds "60"/["0"]. Specifies the time in seconds after which the registration is automatically expunged by the database. The default is "0": the registration lives until explicitly deregistered.
  • OracleConnection.NTF_LOCAL_TCP_PORT: "1234"/[NTF_DEFAULT_TCP_PORT]. This option lets you specify what TCP port the driver should use for the listening socket. If you don't specify a port, the driver will use NTF_DEFAULT_TCP_PORT and if it's already used, it will increment it by one until it finds one that is available.
  • OracleConnection.NTF_LOCAL_HOST: example "212.121.134.12". Use this option to manually specify the IP address of the machine that will receive the notifications from the server. Use this option with caution: only specify the IP address of the local machine when the driver is unable to find it out on its own (it uses InetAddress.getLocalHost() ). For example if the machine on which runs the JDBC driver is a VPN client, you may have to specify the IP address of the VPN client which the driver cannot find out on its own. This option should not be used to attempt to have a different remote host receive the notifications from the server.
  • OracleConnection.DCN_NOTIFY_ROWIDS: "true"/["false"]. Use this option to have the server send the ROWIDs of the row that have changed within the notification event. By default this feature is turned off.
  • OracleConnection.DCN_IGNORE_INSERTOP: "true"/["false"]. Use this option to tell the server to ignore INSERT operations.
  • OracleConnection.DCN_IGNORE_UPDATEOP: "true"/["false"]. Use this options to tell the server to ignore UPDATE operations.
  • OracleConnection.DCN_IGNORE_DELETEOP: "true"/["false"]. Use this options to tell the server to ignore DELETE operations.
  • OracleConnection.DCN_NOTIFY_CHANGELAG: "30"/["0"]. This is an int value (specified as a String), that can be used to specify the number of transactions by which the client is willing to lag behind. This option can be used by the client as a throttling mechanism for database change events. When this option is chosen, ROWID level granularity of information will not be available in the events, even if the DCN_NOTIFY_ROWIDS option was set to "true".
  • OracleConnection.DCN_QUERY_CHANGE_NOTIFICATION: "true"/["false"]. Use this option to activate query change notification instead of object change notification. Note that this option is only available in the database server starting in 11.1.
  • OracleConnection.DCN_BEST_EFFORT: "true"/["false"]. If a query has been successfully registered, by default there will be no FALSE positives. If this option is selected during registrations, then registrations on complex queries may still be allowed but notifications may have some FALSE positives, because full pruning may not be performed if determined to be too expensive. In the worst case notifications will be generated in response to any DML/DDL changes to underlying objects. Note that this option is ignored if the DCN_QUERY_CHANGE_NOTIFICATION isn't turned on. As DCN_QUERY_CHANGE_NOTIFICATION, this option is only available in the database server starting in 11.1.
  • OracleConnection.NTF_GROUPING_CLASS: OracleConnection.NTF_GROUPING_CLASS_TIME/[OracleConnection.NTF_GROUPING_CLASS_NONE]. Notification Grouping Class, the criterion or dimension for grouping. The only supported class is OracleConnection.NTF_GROUPING_CLASS_TIME meaning grouping by time, that is, the user specifies a time value and a single notification gets published at the end of that time. To use grouping at least this option must be specified to a value other than the default OracleConnection.NTF_GROUPING_CLASS_NONE, which is no grouping.
  • OracleConnection.NTF_GROUPING_VALUE: "1200/["600"]. Notification Grouping Value, the value of the grouping class. The value must be an integer number. For the TIME grouping class, this value represents a number of seconds, meaning the time after which grouped notifications are sent. If not specified, it defaults to 600 sec.
  • OracleConnection.NTF_GROUPING_TYPE: OracleConnection.NTF_GROUPING_TYPE_LAST/[OracleConnection.NTF_GROUPING_TYPE_SUMMARY]. Notification Grouping Type, the format of grouping notification. It can either contain the summary of all events (default) or the last event in the group.
  • OracleConnection.NTF_GROUPING_START_TIME: When to start grouping? Notification grouping can start from a user-specified time that should a valid timestamp with time zone, that is an instance of oracle.sql.TIMESTAMPTZ. If this option is not specified when using grouping, it defaults to current system time. For example if prop was the option properties, and conn the connection object, you would call: prop.put(OracleConnection.NTF_GROUPING_START_TIME,new TIMESTAMPTZ(conn,"2007-06-21 10:10:00.0"));.
  • OracleConnection.NTF_GROUPING_REPEAT_TIME: "100"/[NTF_GROUPING_REPEAT_FOREVER]. How many times do grouping? Grouping notifications will be sent as many times as specified by the notification grouping repeat count and after that revert to regular notifications. If not specified, it will default to: NTF_GROUPING_REPEAT_FOREVER - keep sending grouping notifications forever.
Returns:
DatabaseChangeRegistration
Throws:
java.sql.SQLException

getDatabaseChangeRegistration

public DatabaseChangeRegistration getDatabaseChangeRegistration(int regid)
                                                         throws java.sql.SQLException
Description copied from interface: OracleConnection
Maps an existing registration identified by its ID 'regid' with a new DatabaseChangeRegistration object.

This method can be used if you create a registration through PLSQL and you want to associate a JDBC statement with it.

This method doesn't create a new listener on the JDBC driver side and DatabaseChangeEvent won't be created. Thus you won't be allowed to attach any listeners to this registration.

Note that this method doesn't generate any roundtrip to the database.

Specified by:
getDatabaseChangeRegistration in interface OracleConnection
Parameters:
regid - The id of the registration
Returns:
DatabaseChangeRegistration A new instance that can be used to associate a statement with this registration
Throws:
java.sql.SQLException

unregisterDatabaseChangeNotification

public void unregisterDatabaseChangeNotification(DatabaseChangeRegistration registration)
                                          throws java.sql.SQLException
Description copied from interface: OracleConnection
Deletes a given database change registration. The registration will be destroyed in the server and in the driver (the network listener will be closed if it's not used anymore).

This method interrupts the notification thread and removes all listeners attached to this registration before closing it.

Specified by:
unregisterDatabaseChangeNotification in interface OracleConnection
Throws:
java.sql.SQLException
See Also:
OracleConnection.unregisterDatabaseChangeNotification(long,String)

unregisterDatabaseChangeNotification

public void unregisterDatabaseChangeNotification(int registrationId,
                                                 java.lang.String host,
                                                 int tcpport)
                                          throws java.sql.SQLException
Description copied from interface: OracleConnection
Deletes a given database change registration in the server. This method doesn't free any resources in the drivers.

This method will throw an "ORA-24950: unregister failed, registration not found" if you don't provide the correct TCP port which can be extracted from the "callback" value in the "USER_CHANGE_NOTIFICATION_REGS" table.

Specified by:
unregisterDatabaseChangeNotification in interface OracleConnection
Throws:
java.sql.SQLException
See Also:
OracleConnection.unregisterDatabaseChangeNotification(long,String)

unregisterDatabaseChangeNotification

public void unregisterDatabaseChangeNotification(int registrationId)
                                          throws java.sql.SQLException
Description copied from interface: OracleConnection
Deletes a given database change registration in the server. This method doesn't free any resources in the drivers.
Specified by:
unregisterDatabaseChangeNotification in interface OracleConnection
Throws:
java.sql.SQLException
See Also:
OracleConnection.unregisterDatabaseChangeNotification(long, String)

unregisterDatabaseChangeNotification

public void unregisterDatabaseChangeNotification(long registrationId,
                                                 java.lang.String callback)
                                          throws java.sql.SQLException
Description copied from interface: OracleConnection
Deletes a given database change registration in the server. This method doesn't free any resources in the drivers and should only be used to clean up a registration in the database that wasn't properly closed (in the case of JVM crash for example).

This flavor of unregisterDatabaseChangeNotification can be used to process the result of the following query: select regid,callback from USER_CHANGE_NOTIFICATION_REGS;.

For example to remove all registrations from the database you would execute the following code:

    Statement stmt= conn.createStatement();
    ResultSet rs = stmt.executeQuery("select regid,callback from USER_CHANGE_NOTIFICATION_REGS");
    while(rs.next())
    {
      long regid = rs.getLong(1);
      String callback = rs.getString(2);
      ((OracleConnection)conn).unregisterDatabaseChangeNotification(regid,callback);
    }
    rs.close();
    stmt.close();
    
Specified by:
unregisterDatabaseChangeNotification in interface OracleConnection
Throws:
java.sql.SQLException
See Also:
OracleConnection.unregisterDatabaseChangeNotification(oracle.jdbc.dcn.DatabaseChangeRegistration)

registerAQNotification

public AQNotificationRegistration[] registerAQNotification(java.lang.String[] name,
                                                           java.util.Properties[] options,
                                                           java.util.Properties globaloptions)
                                                    throws java.sql.SQLException
Description copied from interface: OracleConnection
Registers your interest into being notified when a message is enqueued in a particular queue (or array of queues).

This method creates an array of new AQ registrations in the database server with the given options. It also opens a listening socket which will be used by the database to send notifications. Note that mutiple registrations can share the same listening socket.

Each registration will continue to live after this connection is closed. You need to explicitly unregister it to destroy it in the server and release the resources in the driver.

This method uses one roundtrip.

Specified by:
registerAQNotification in interface OracleConnection
Parameters:
name - contains an array of queue names ("SCOTT.MY_QUEUE") for single consumer queues or queue names with the consumer name ("SCOTT.MY_QUEUE:RECEIVER") for multiple consumer queues.
options - Possible options are ([] means default):
  • OracleConnection.NTF_QOS_RELIABLE: "true"/["false"]. Set this option to "true" to make the notifications persistent which comes at a performance cost.
  • OracleConnection.NTF_QOS_PURGE_ON_NTFN: "true"/["false"]. Set this option to "true" and the registration will be expunged on the first notification event.
  • OracleConnection.NTF_TIMEOUT: value in seconds "60"/["0"]. Specifies the time in seconds after which the registration is automatically expunged by the database. The default is "0": the registration lives until explicitly deregistered.
  • OracleConnection.NTF_AQ_PAYLOAD: "true"/["false"]. Sets this to "true" to make the server send the payload within the notification. Note that this feature works only with "RAW" payloads.
  • OracleConnection.NTF_GROUPING_CLASS: OracleConnection.NTF_GROUPING_CLASS_TIME/[OracleConnection.NTF_GROUPING_CLASS_NONE]. Notification Grouping Class, the criterion or dimension for grouping. As of 11.2 the only supported class is OracleConnection.NTF_GROUPING_CLASS_TIME meaning grouping by time, that is, the user specifies a time value and a single notification gets published at the end of that time. To use grouping at least this option must be specified to a value other than the default OracleConnection.NTF_GROUPING_CLASS_NONE, which is no grouping.
  • OracleConnection.NTF_GROUPING_VALUE: "1200/["600"]. Notification Grouping Value, the value of the grouping class. The value must be an integer number. For the TIME grouping class, this value represents a number of seconds, meaning the time after which grouped notifications are sent. If not specified, it defaults to 600 sec.
  • OracleConnection.NTF_GROUPING_TYPE: OracleConnection.NTF_GROUPING_TYPE_LAST/[OracleConnection.NTF_GROUPING_TYPE_SUMMARY]. Notification Grouping Type, the format of grouping notification. It can either contain the summary of all events (default) or the last event in the group.
  • OracleConnection.NTF_GROUPING_START_TIME: When to start grouping? Notification grouping can start from a user-specified time that should a valid timestamp with time zone, that is an instance of oracle.sql.TIMESTAMPTZ. If this option is not specified when using grouping, it defaults to current system time. For example if prop was the option properties, and conn the connection object, you would call: prop.put(OracleConnection.NTF_GROUPING_START_TIME,new TIMESTAMPTZ(conn,"2007-06-21 10:10:00.0"));.
  • OracleConnection.NTF_GROUPING_REPEAT_TIME: "100/[NTF_GROUPING_REPEAT_FOREVER]". How many times do grouping? Grouping notifications will be sent as many times as specified by the notification grouping repeat count and after that revert to regular notifications. If not specified, it will default to: NTF_GROUPING_REPEAT_FOREVER - keep sending grouping notifications forever.
globaloptions - Possible options are ([] means default):
  • OracleConnection.NTF_LOCAL_TCP_PORT: "1234"/[NTF_DEFAULT_TCP_PORT]. This option lets you specify what TCP port the driver should use for the listening socket. If you don't specify a port, the driver will use NTF_DEFAULT_TCP_PORT and if it's already used, it will increment it by one until it finds one that is available.
  • OracleConnection.NTF_LOCAL_HOST: example "212.121.134.12". Use this option to manually specify the IP address of the machine that will receive the notifications from the server. Use this option with caution: only specify the IP address of the local machine when the driver is unable to find it out on its own (it uses InetAddress.getLocalHost() ). For example if the machine on which runs the JDBC driver is a VPN client, you may have to specify the IP address of the VPN client which the driver cannot find out on its own. This option should not be used to attempt to have a different remote host receive the notifications from the server.
Returns:
AQNotificationRegistration[]
Throws:
java.sql.SQLException

unregisterAQNotification

public void unregisterAQNotification(AQNotificationRegistration registration)
                              throws java.sql.SQLException
Description copied from interface: OracleConnection
Deletes a given AQ registration. The registration will be destroyed in the server and in the driver (the network listener will be closed if it's not used anymore).
Specified by:
unregisterAQNotification in interface OracleConnection
Throws:
java.sql.SQLException

dequeue

public AQMessage dequeue(java.lang.String queueName,
                         AQDequeueOptions opt,
                         byte[] tdo)
                  throws java.sql.SQLException
Description copied from interface: OracleConnection
Dequeues an AQ message from the queue specified by its name.
Specified by:
dequeue in interface OracleConnection
Parameters:
queueName - name of the queue from which to dequeue.
opt - dequeue options
tdo - the Type Descriptor Object OID of the type of the queue.
Returns:
the AQMessage dequeued.
Throws:
java.sql.SQLException

dequeue

public AQMessage dequeue(java.lang.String queueName,
                         AQDequeueOptions opt,
                         java.lang.String typeName)
                  throws java.sql.SQLException
Description copied from interface: OracleConnection
Dequeues an AQ message from the queue specified by its name.
Specified by:
dequeue in interface OracleConnection
Parameters:
queueName - name of the queue from which to dequeue.
opt - dequeue options.
typeName - the name of the type of the queue. For example, it can be "RAW", "SYS.ANYDATA" or "SCOTT.MY_OBJECT_TYPE".
Returns:
the AQMessage dequeued.
Throws:
java.sql.SQLException

enqueue

public void enqueue(java.lang.String queueName,
                    AQEnqueueOptions opt,
                    AQMessage mesg)
             throws java.sql.SQLException
Description copied from interface: OracleConnection
Enqueues the given AQ message to the queue specified by its name.
Specified by:
enqueue in interface OracleConnection
Parameters:
queueName - name of the queue where to enqueue.
opt - enqueue options.
mesg - the AQ message to enqueue.
Throws:
java.sql.SQLException

commit

public void commit(java.util.EnumSet<OracleConnection.CommitOption> flags)
            throws java.sql.SQLException
Description copied from interface: OracleConnection
Commits the transaction with the given options.
Specified by:
commit in interface OracleConnection
Throws:
java.sql.SQLException

cancel

public void cancel()
            throws java.sql.SQLException
Description copied from interface: OracleConnection
Performs an immediate (asynchronous) termination of any currently executing operation on this connection. It is normally used to stop a long-running JDBC call being processed on the server. It can be called by a user thread in multithreaded applications.

For example, in the context of AQ, it can be used to cancel a 'dequeue' call that is waiting for a new message to be enqueued.

Specified by:
cancel in interface OracleConnection
Throws:
java.sql.SQLException - if the cancel operation fails

abort

public void abort()
           throws java.sql.SQLException
Description copied from interface: OracleConnection
Calling abort() on an open connection does the following: marks the connection as closed, closes any sockets or other primitive connections to the database, and insures that any thread that is currently accessing the connection will either progress to completion of the JDBC call or throw an exception. Calling abort() on a closed connection does nothing. It is critical to note that abort() does not hang. It does not block because of pending database operations. In particular it is not synchronized. Since typically abort() will be called when it appears that the connection is dead, any attempt to communicate with the database via blocking IO is likely to hang and is not attempted. As such, abort leaves the connection in a unknown state. Although abort marks the connection as closed, it does not release any local resources as it cannot do so safely; it is not synchronized. It is recommended to call Connection.close() after calling abort. Connection.close() will recognize that connection has been aborted and will clean up local resources, even though the connection has already been marked as closed. Since Connection.close is synchronized it may hang briefly while any thread that has a lock on the connection completes and releases the lock. Recall that after calling abort any thread that is using the connection will be able to proceed to completion or will throw an exception. abort is very different from OracleConnection.cancel. cancel gracefully stops the execution of any SQL operation. It is a synchronous operation that communicates with the database. It leaves the connection and the statements in a well-known and usable state. In contrast abort tears down the client side network connection to the database, leaving the server to clean up as best it can whenever it discovers that the connection has been broken. abort does not clean up client side resources and leaves the connection and associated statements in an unknown and unusable state. The only valid thing to do with a connection after calling abort is to call close and then discard the connection object. After calling cancel the app can continue to use the connection and statements. If there is a security manager, its checkPermission method is called with an oracle.jdbc.OracleSQLPermission("callAbort") permission to see if the caller has permission to abort a connection. If the caller does not have permission, a SecurityException is thrown. See the ojdbc.policy file in the demo directory for help in granting the appropriate permissions when using a SecurityManager with Oracle JDBC. The best use of the abort() call is in the layer that manages connections such as the connection pool. Stale or invalid connections may often appear to hang when an application thread is blocked on a network call. Connection pools may implement a cleaner thread, that simply looks for such stale connections and issues the abort() call. This results in releasing all client handles and resources without expecting an acknowledgement from the database backend. There is no need for user code to call abort when using an Oracle connection pool such as the Implicit Connection Cache or the Universal Connection Pool as these connection pools will call abort when necessary.
Specified by:
abort in interface OracleConnection
Throws:
java.sql.SQLException - -- Io Exception: Socket closed - ORA-17002 TNS:not connected - ORA-12153

getAllTypeDescriptorsInCurrentSchema

public TypeDescriptor[] getAllTypeDescriptorsInCurrentSchema()
                                                      throws java.sql.SQLException
Description copied from interface: OracleConnection
Obtain all the type descriptors associated with object types or array in the schema of this connection. Note that synonyms are not suportted. Requires an internal PL/SQL package that is present only in database 11 and above.
Specified by:
getAllTypeDescriptorsInCurrentSchema in interface OracleConnection
Returns:
An array of the appropriate descriptors for Arrays or Structs depending on the type names found.
Throws:
java.sql.SQLException - If an error occurs.

getTypeDescriptorsFromListInCurrentSchema

public TypeDescriptor[] getTypeDescriptorsFromListInCurrentSchema(java.lang.String[] typeNames)
                                                           throws java.sql.SQLException
Description copied from interface: OracleConnection
Obtain the type descriptors associated with object types or array in a schema from an array of type names. Note that synonyms are not suportted. Requires an internal PL/SQL package that is present only in database 11 and above.
Specified by:
getTypeDescriptorsFromListInCurrentSchema in interface OracleConnection
Returns:
An array of the appropriate descriptors for Arrays or Structs depending on the type names found.
Throws:
java.sql.SQLException - if the specified type does not exist, or if an error occurred.

getTypeDescriptorsFromList

public TypeDescriptor[] getTypeDescriptorsFromList(java.lang.String[][] schemaAndTypeNamePairs)
                                            throws java.sql.SQLException
Description copied from interface: OracleConnection
Obtain the type descriptors associated with object types or arrays from an array of scheama and type names. Note that synonyms are not suportted. Requires an internal PL/SQL package that is present only in database 11 and above.
Specified by:
getTypeDescriptorsFromList in interface OracleConnection
Returns:
An array of the appropriate descriptors for Arrays or Structs depending on the type names found.
Throws:
java.sql.SQLException - if any of the specified types does not exist, or if an error occurs.

getDataIntegrityAlgorithmName

public java.lang.String getDataIntegrityAlgorithmName()
                                               throws java.sql.SQLException
Description copied from interface: OracleConnection
Returns the name of the algorithm that is used for data integrity checking by the thin driver on the network. Returns "" when there is no data integrity checking.
Specified by:
getDataIntegrityAlgorithmName in interface OracleConnection
Throws:
java.sql.SQLException

getEncryptionAlgorithmName

public java.lang.String getEncryptionAlgorithmName()
                                            throws java.sql.SQLException
Description copied from interface: OracleConnection
Returns the name of the algorithm that is used for data encryption by the thin driver on the network. Returns "" when the data isn't encrypted on the network.
Specified by:
getEncryptionAlgorithmName in interface OracleConnection
Throws:
java.sql.SQLException

getAuthenticationAdaptorName

public java.lang.String getAuthenticationAdaptorName()
                                              throws java.sql.SQLException
Description copied from interface: OracleConnection
Returns the name of the adaptor that is used for authentication by the thin driver. Returns "" for basic user/password authenticatin.
Specified by:
getAuthenticationAdaptorName in interface OracleConnection
Throws:
java.sql.SQLException

isUsable

public boolean isUsable()
Description copied from interface: OracleConnection
Identifies whether this connection is still usable for JDBC operations.
Specified by:
isUsable in interface OracleConnection
Returns:
true if this connection is usable; false otherwise.

setDefaultTimeZone

public void setDefaultTimeZone(java.util.TimeZone tz)
                        throws java.sql.SQLException
The TimeZone to be used while creating java.sql.Date, java.sql.Time & java.sql.Timestamp.
Specified by:
setDefaultTimeZone in interface OracleConnection
Parameters:
Default - TimeZone to be used for all Date, Time and Timestamp conversions.
Throws:
java.sql.SQLException - if there is an issue while setting the TimeZone

getDefaultTimeZone

public java.util.TimeZone getDefaultTimeZone()
                                      throws java.sql.SQLException
Returns the TimeZone set through setDefaultTimeZone.
Specified by:
getDefaultTimeZone in interface OracleConnection
Returns:
TimeZone set through setDefaultTimeZone. Returns null if TimeZone if setDefaultTimeZone in not invoked with proper values.
Throws:
java.sql.SQLException - If there is any issue while retrieving the TimeZone

setApplicationContext

public void setApplicationContext(java.lang.String nameSpace,
                                  java.lang.String attribute,
                                  java.lang.String value)
                           throws java.sql.SQLException
Description copied from interface: OracleConnection
Sets a attribute/value pair in a particular namespace in the application context on the server. This application context is stored in the user session. Note that you can call this method multiple times to set more than one attribute/value pair in the application context. Please note that the only supported namespace is CLIENTCONTEXT. More may be added in a future release. This method does not require any additional roundtrip.
Specified by:
setApplicationContext in interface OracleConnection
Parameters:
nameSpace - The namespace where this attribute/value pairs will be stored. The only supported namespace is CLIENTCONTEXT. The value cannot be null nor empty.
attribute - The attribute whose value needs to be set. If the value is null then a NullPointerException is thrown. If the value is an empty string (""), then the namespace will be cleared and the value is ignored.
value - The value of the attribute. If the value is null then a NullPointerException is thrown. If the value is an empty string (""), then the attribute will be cleared.
Throws:
java.sql.SQLException - If an error occurs
See Also:
clearAllApplicationContext

clearAllApplicationContext

public void clearAllApplicationContext(java.lang.String nameSpace)
                                throws java.sql.SQLException
Description copied from interface: OracleConnection
Clear all the attribute/value information in a namespace.
Specified by:
clearAllApplicationContext in interface OracleConnection
Parameters:
nameSpace - The namespace which will be cleared
Throws:
java.sql.SQLException
See Also:
setApplicationContext

Skip navigation links

Oracle Database JDBC Java API Reference
11g Release 2

E13995-03


Copyright © 2009, Oracle and/or its affiliates. All rights reserved.