ca.idms.jdbc
Class IdmsConnectOptions

java.lang.Object
  extended by ca.idms.jdbc.IdmsConnectOptions
All Implemented Interfaces:
IdmsDriverInterface

public class IdmsConnectOptions
extends java.lang.Object
implements IdmsDriverInterface

This class defines connection options for IDMS. On Windows, connection options are usually specified in the registry. The most commonly used options can be set using the ODBC Administrator. All options can be set by manually editing the registry. The property names defined in this class are the value names.

On OS/390, z/OS, and Linux on both the mainframe and PC, connection options can be specified in the IDMS configuration file, which is formatted like a Windows "ini" file. The property names defined in this class are the key names.

On all platforms, connection options can be specified in the IDMS properties file, which is formatted as a standard Java properties file. The property names defined in this are appended to "Options." to form the key in the properties file. These properties can also be specified as system properties when prefixed with the system property prefix.

When an option is specified in more than one place, a value from the registry or configuration file overrides a value from the properties file, which overrides the value set as a system property. For compatibility with the registry and ini file conventions, boolean options are usually set as "integer" values, where 1 is "true" and 0 is "false".

Author:
Dave Ross
See Also:
IdmsConnection, TraceObject

Field Summary
static java.lang.String ACCESSIBLE_TABLES
          Property name to enable an alternate view for IdmsDatabaseMetaData.getTables(java.lang.String, java.lang.String, java.lang.String, java.lang.String[]).
static java.lang.String CALL_OUTPUT_ALL
          Property name to force an SQL CALL statement to return all parameters defined in the CREATE PROCEDURE statement instead of returning only those specified in the CALL statement.
static java.lang.String CALL_SELECT
          Property name to force an SQL CALL statement to be treated as a SELECT.
static java.lang.String CATALOG_TABLE
          Property name to specify an alternate view for IdmsDatabaseMetaData.getTables(java.lang.String, java.lang.String, java.lang.String, java.lang.String[]) when ACCESSIBLE_TABLES is enabled.
static java.lang.String CLOSE_COMMIT
          Property name to force a COMMIT on each CLOSE CURSOR.
static java.lang.String COMMIT_BEHAVIOR
          Property name to set the default "ResultSetHoldability".
static java.lang.String COMMIT_SUSPEND
          Property name to force a SUSPEND after each COMMIT.
static java.lang.String CONNECT_SUSPEND
          Property name to force a SUSPEND immediately after CONNECT.
static int CSATST06
          SERVER_TRACE = 67108864 - enable #DBTRACE.
static int CSATST08
          SERVER_TRACE = 16777216 - enable #WTL.
static int CSATST16
          SERVER_TRACE = 65536 - enable #SNAP.
static java.lang.String DEFAULT_SCHEMA
          Property name to specify a default schema for all SQL operations using this connection.
static java.lang.String DESCRIBE_EXTENDED
          Property name to enable the return of extended descriptors.
static java.lang.String FETCH_ROWS
          Property name to set the default "FetchSize".
static java.lang.String FETCH_SUSPEND
          Property name to force a SUSPEND on each FETCH.
static java.lang.String FETCH_SUSPEND_C
          Deprecated. This is now the default behavior
static java.lang.String FORCE_DESCRIBE
          Property name to force an IdmsPreparedStatement or IdmsCallableStatement object to attempt to use descriptors from the database for input parameters instead of default descriptors.
static java.lang.String JDBC_TRACE
          Property name to enable the global JDBC trace.
static java.lang.String JDBC_TRACE_ID
          Property name to identify IDMS output in the JDBC log writer trace.
static java.lang.String LOGIN_TIMEOUT
          Property name to set the default loginTimeout.
static java.lang.String OPTIONS
          Prefix for IDMS options.
static java.lang.String POOL_SUSPEND
          Deprecated. use the IdmsDriverInterface.INTERACTIVE suspend strategy, or the IdmsDriverInterface.CUSTOM strategy with COMMIT_SUSPEND instead.
static java.lang.String PRESERVE_PREPARED
          Property name to force prepared statements to be preserved.
static java.lang.String QUERY_TIMEOUT
          Property name to set the default queryTimeout.
static java.lang.String READ_ONLY
          Property name to set the default access mode to read only.
static java.lang.String SERVER_TRACE
          Property name to enable the IDMSJSRV server trace.
static java.lang.String SUSPEND_STRATEGY
          Property name to specify a suspend strategy.
static java.lang.String TXN_ISOLATION
          Property name to set the default transaction isolation.
static java.lang.String WAIT_TIMEOUT
          Property name to set the system default socket timeout in seconds.
 
Fields inherited from interface ca.idms.jdbc.IdmsDriverInterface
ACCOUNT, BATCH, CCIHOST, CCIPORT, CSUSPEND, CUSTOM, DEF_CCIPORT, DEF_TASK, DEFSCHEM, EWAIT, INFO, INTERACTIVE, NODE, PASSWORD, PROGRAM, RSINT, SBUFLEN, SERVICE, SSL, STRACE, SUSPEND, TASK, USER, VIA
 
Method Summary
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

OPTIONS

public static final java.lang.String OPTIONS
Prefix for IDMS options. "Options" is used as follows:

See Also:
"CA IDMS Server User Guide", Constant Field Values

JDBC_TRACE

public static final java.lang.String JDBC_TRACE
Property name to enable the global JDBC trace. Set "JdbcTrace" to 1 to enable, 0 to disable. On Windows this option can be set in the registry using the ODBC Administrator.

See Also:
"CA IDMS Server User Guide", Constant Field Values

JDBC_TRACE_ID

public static final java.lang.String JDBC_TRACE_ID
Property name to identify IDMS output in the JDBC log writer trace. Set "JdbcTraceId" to 1 to prefix each line writen to the JDBC log writer with the timestamp and current thread name. The default is 0.

See Also:
Constant Field Values

SERVER_TRACE

public static final java.lang.String SERVER_TRACE
Property name to enable the IDMSJSRV server trace. The value specified will be passed to the server task.
CSATST06
#DBTRACE
CSATST08
#WTL calls
CSATST16
#SNAP data

See Also:
Constant Field Values

CSATST06

public static final int CSATST06
SERVER_TRACE = 67108864 - enable #DBTRACE.

See Also:
Constant Field Values

CSATST08

public static final int CSATST08
SERVER_TRACE = 16777216 - enable #WTL.

See Also:
Constant Field Values

CSATST16

public static final int CSATST16
SERVER_TRACE = 65536 - enable #SNAP.

See Also:
Constant Field Values

ACCESSIBLE_TABLES

public static final java.lang.String ACCESSIBLE_TABLES
Property name to enable an alternate view for IdmsDatabaseMetaData.getTables(java.lang.String, java.lang.String, java.lang.String, java.lang.String[]). Set "AccessibleTables" to 1 to enable (the default), 0 to disable. Compatible with the ODBC driver option.

See Also:
Constant Field Values

CALL_SELECT

public static final java.lang.String CALL_SELECT
Property name to force an SQL CALL statement to be treated as a SELECT. Set "CallSelect" to 1 to enable, 0 to disable.

See Also:
Constant Field Values

CALL_OUTPUT_ALL

public static final java.lang.String CALL_OUTPUT_ALL
Property name to force an SQL CALL statement to return all parameters defined in the CREATE PROCEDURE statement instead of returning only those specified in the CALL statement. Set "CallOutputAll" to 1 to enable, 0 to disable.

See Also:
Constant Field Values

CATALOG_TABLE

public static final java.lang.String CATALOG_TABLE
Property name to specify an alternate view for IdmsDatabaseMetaData.getTables(java.lang.String, java.lang.String, java.lang.String, java.lang.String[]) when ACCESSIBLE_TABLES is enabled. Compatible with the ODBC driver option.

See Also:
Constant Field Values

CLOSE_COMMIT

public static final java.lang.String CLOSE_COMMIT
Property name to force a COMMIT on each CLOSE CURSOR. Set "CloseCommit" to 1 to enable, 0 to disable.

See Also:
"CA IDMS Server User Guide", Constant Field Values

COMMIT_SUSPEND

public static final java.lang.String COMMIT_SUSPEND
Property name to force a SUSPEND after each COMMIT. Set "CommitSuspend" to 1 to enable, 0 to disable.

See Also:
"CA IDMS Server User Guide", Constant Field Values

CONNECT_SUSPEND

public static final java.lang.String CONNECT_SUSPEND
Property name to force a SUSPEND immediately after CONNECT. Set "ConnectSuspend" to 1 to enable, 0 to disable.

See Also:
"CA IDMS Server User Guide", Constant Field Values

DEFAULT_SCHEMA

public static final java.lang.String DEFAULT_SCHEMA
Property name to specify a default schema for all SQL operations using this connection.

See Also:
Constant Field Values

DESCRIBE_EXTENDED

public static final java.lang.String DESCRIBE_EXTENDED
Property name to enable the return of extended descriptors.

When this is enabled and the server is CA IDMS r16 or later, the IdmsResultSetMetaData getSchemaName and getTableName methods identify the table for each column in a resultSet, unless the column is an expression.

This is disabled by default because the current implementation in CA IDMS r16 and r17 causes a ROWID column to be inserted into the result set for each table that contains columns in the result set.

Set "DescribeExtended" to 1 to enable, 0 to disable.

See Also:
Constant Field Values

FETCH_ROWS

public static final java.lang.String FETCH_ROWS
Property name to set the default "FetchSize". Set "FetchRows" to the requested number of rows per BULK FETCH. On Windows this option can be set in the registry using the ODBC Administrator, and is used by both the ODBC and JDBC drivers.

See Also:
"CA IDMS Server User Guide", Constant Field Values

FETCH_SUSPEND

public static final java.lang.String FETCH_SUSPEND
Property name to force a SUSPEND on each FETCH. Set "FetchSuspend" to 1 to enable, 0 to disable.

See Also:
"CA IDMS Server User Guide", Constant Field Values

FETCH_SUSPEND_C

public static final java.lang.String FETCH_SUSPEND_C
Deprecated. This is now the default behavior
Property name to force a SUSPEND on each FETCH only after CLOSE. Set "FetchSuspendClose" to 1 to enable, 0 to disable.

See Also:
"CA IDMS Server User Guide", Constant Field Values

FORCE_DESCRIBE

public static final java.lang.String FORCE_DESCRIBE
Property name to force an IdmsPreparedStatement or IdmsCallableStatement object to attempt to use descriptors from the database for input parameters instead of default descriptors.

When this is disabled (the default) and the SQL statement is SELECT or CALL), the driver defers the PREPARE until the statement is executed, if possible, which allows an OPEN to be piggybacked on the request. The driver uses default descriptors, based on the setXXX method, setNull type, or registerOutParameter type, to build the the internal SQLDA used to describe the parameter buffer.

When this is enabled or the SQL statement is INSERT, UPDATE, or DELETE with parameter markers, the driver issues the PREPARE with DESCRIBE INPUT before it sets or registers any parameters, and use the descriptors returned from the database, if compatible with the type implied by the setXXX method, setNull type, or registerOutParameter type. A separate OPEN will be issued when the SQL statement is SELECT or CALL.

Note that the statement is also PREPARED and DESCRIBED when an application invokes the getMetaData or getParameterMetaData method.

Set "ForceDescribe" to 1 to enable, 0 to disable.

See Also:
Constant Field Values

POOL_SUSPEND

public static final java.lang.String POOL_SUSPEND
Deprecated. use the IdmsDriverInterface.INTERACTIVE suspend strategy, or the IdmsDriverInterface.CUSTOM strategy with COMMIT_SUSPEND instead.
Property name to enable SUSPEND while a pooled connection is in use. Starting with CA IDMS Server 16.0, the SUSPEND behavior of pooled connections is optimized for application servers. A SUSPEND only occurs when the application logically closes the connection, allowing the connection pool manager to return it to the idle pool. When this option is enabled pooled connections will behave like non-pooled connections as they did in previous releases. Set "PoolSuspendActive" to 1 to enable, 0 to disable (the default). This is meant as an escape hatch for backwards compatibility only.

See Also:
Constant Field Values

SUSPEND_STRATEGY

public static final java.lang.String SUSPEND_STRATEGY
Property name to specify a suspend strategy. Set "SuspendStrategy" to one of: For compatibility set "SuspendStrategy" to IdmsDriverInterface.CUSTOM, which is the default if not specified as a Connection or DataSource property, to enable the detailed options:

See Also:
"CA IDMS Server User Guide", Constant Field Values

READ_ONLY

public static final java.lang.String READ_ONLY
Property name to set the default access mode to read only. Set "ReadOnly" to 1 for READ ONLY, 0 for READ WRITE (the default). On Windows this option can be set in the registry using the ODBC Administrator, and is used by both the ODBC and JDBC drivers.

See Also:
"CA IDMS Server User Guide", Constant Field Values

TXN_ISOLATION

public static final java.lang.String TXN_ISOLATION
Property name to set the default transaction isolation. Set "TxnIsolation" to a Transaction Isolation mode as defined by ODBC:
1 = READ UNCOMMITTED
Connection.TRANSACTION_READ_UNCOMMITTED = 1
2 = READ COMMITTED
Connection.TRANSACTION_READ_COMMITTED = 2
The default is 2, READ_COMMITED. On Windows this option can be set in the registry using the ODBC Administrator, and is used by both the ODBC and JDBC drivers.

See Also:
"CA IDMS Server User Guide", Constant Field Values

COMMIT_BEHAVIOR

public static final java.lang.String COMMIT_BEHAVIOR
Property name to set the default "ResultSetHoldability". Set "CommitBehavior" to a Commit Behavior as defined by ODBC:
0 = DELETE
ResultSet.CLOSE_CURSORS_AT_COMMIT = 2
1 = CLOSE
ResultSet.CLOSE_CURSORS_AT_COMMIT = 2
2 = PRESERVE
ResultSet.HOLD_CURSORS_OVER_COMMIT = 1
The default is 1, CLOSE CURSORS. Note that DELETE and CLOSE are equivalent for the JDBC driver. PRESERVE is not compatible with an XAConnection and is converted to CLOSE at run time. On Windows this option can be set in the registry using the ODBC Administrator, and is used by both the ODBC and JDBC drivers.

See Also:
"CA IDMS Server User Guide", Constant Field Values

PRESERVE_PREPARED

public static final java.lang.String PRESERVE_PREPARED
Property name to force prepared statements to be preserved. When enabled, the driver will attempt to preserve prepared statements when a transaction is committed and the commit behavior is PRESERVE, that is, ResultSetHoldability is ResultSet.HOLD_CURSORS_OVER_COMMIT.

Starting with CA IDMS Server r17, the driver ignores the existence of any prepared statements when committing a transaction. The driver re-prepares the statement from the locally cached syntax as needed. When the SQL caching feature, available with CA IDMS r16, is enabled this has a minimal impact on performance.

This option restores the legacy behavior. The default is false.

See Also:
Constant Field Values

WAIT_TIMEOUT

public static final java.lang.String WAIT_TIMEOUT
Property name to set the system default socket timeout in seconds. This property specifies the the global socket timeout in seconds. It is used for all requests to the server and applies to the Java socket interface used by the JDBC driver (Type 3 and Type 4) and the native socket interface used by the JDBC driver (Type 2) and the ODBC driver.

In most cases, a value of 0 specifies that there is no timeout, and socket requests will wait indefinitely. When the native socket interface is CAICCI, a value of 0 indicates that the reply timeout specified for CAICCI should be used.

Set "WaitTimeOut" to the default socket timeout in seconds.

See Also:
Constant Field Values

LOGIN_TIMEOUT

public static final java.lang.String LOGIN_TIMEOUT
Property name to set the default loginTimeout. The CA IDMS JDBC driver uses the value of the loginTimeout property as the socket reply timeout when connecting to the database and issuing requests not associated with a statement, such as commit and rollback methods.

An application normally uses the DriverManager.setLoginTimeout or IdmsCommonDataSource.setLoginTimeout(int) methods to set the loginTimeout. Setting loginTimeout property to 0 specifies that the default system timeout should be used if there is one, and that there is no timeout if not. This property can be used to override the default system default timeout, specified by WAIT_TIMEOUT, for the loginTimeout.

Set "LoginTimeout" to the default loginTimeout in seconds.

See Also:
Constant Field Values

QUERY_TIMEOUT

public static final java.lang.String QUERY_TIMEOUT
Property name to set the default queryTimeout. The CA IDMS JDBC driver uses the value of the queryTimeout property as the socket reply timeout when for executing a statement and manipulating result sets.

An application normally use the IdmsStatement.getQueryTimeout() method to set the reply timeout value for a specific statement object. Setting queryTimeout property to 0 specifies that the default system timeout should be used if there is one, and that there is no timeout if not. This property can be used to override the default system default timeout, specified by WAIT_TIMEOUT, for the queryTimeout.

Set "QueryTimeout" to the default queryTimeout in seconds.

See Also:
Constant Field Values


Copyright © 2009 CA, All rights reserved