JDBC Type 2 Driver Programmer's Reference for SQL/MX Release 3.1 (H06.23+, J06.12+)
schema SET SCHEMA default-schema-name
mploc SET MPLOC default-location
transaction isolation SET TRANSACTION isolation-level
A process (JVM process) can have multiple SQL/MX contexts within a process.
Holdable Cursors
JDBC/MX driver supports the holdablity attribute for the ResultSet. To use holdable cursors in your JDBC
applications, follow these guidelines:
Use one of the following constants for the holdablity attribute:
com.tandem.sqlmx.SQLMXResultSet.HOLD_CURSORS_OVER_COMMIT
Ensure that when the application calls the method Connection.commit or
Connection.rollback, the HOLD_CURSORS_OVER_COMMIT constant indicates that ResultSet
objects are not closed.
com.tandem.sqlmx.SQLMXResultSet.CLOSE_CURSORS_AT_COMMIT
Ensure that when the application calls the method Connection.commit or
Connection.rollback, the CLOSE_CURSORS_AT_COMMIT constant indicates that ResultSet
objects are closed.
For the ResultSet objects to be holdable over a commit operation, ensure that the SQL statement
that generates the
ResultSet has either stream access mode, or embedded update or delete for table
references.
Use either of the following methods in SQLMXConnection objects to create result sets with holdable
cursors over commit:
createStatement(int resultSetType, int resultSetConcurrency,
int resultSetHoldability)
prepareStatement(String sql, int resultSetType,
int resultSetConcurrency, int resultSetHoldability)
For a demonstration in a sample program, see the holdJdbcMx.java program description.
Connection Pooling
JDBC/MX provides an implementation of connection pooling, where a cache of physical database
connections are assigned to a client connection session and reused for the database activity. Once the
client session is closed, the physical connection is put back into cache for subsequent use. This
implementation contrasts to the basic
DataSource object implementation, where a one-to-one
correspondence exists between client
Connection object and the physical database connection.
Your applications can use connection pooling in the following ways:
Connection Pooling by an Application Server
Connection Pooling Using the Basic DataSource API










