Sun Java System Application Server Enterprise Edition 8.2 Release Notes for Microsoft Windows

PreparedStatement Errors (ID 6170432)

Description 1

If an application generates more than 3000 PreparedStatement objects in one transaction, the following error might occur with DB2:

[sunm][DB2 JDBC Driver] No more available statements.Please recreate your package with a larger dynamicSections value.

Solution 1

Add following properties to the connection pool definition to ensure that the driver rebinds DB2 packages with a larger dynamic sections value:

createDefaultPackage=true replacePackage=true dynamicSections=1000

See the Sun Java System Application Server Enterprise Edition 8.2 Administration Guide for details about configuring connection pools.

Description 2

Related to the PreparedStatement error , another error message that might be thrown:

[sunm][DB2 JDBC Driver][DB2]Virtual storage or database resource is not available.

Solution 2

Increase the DB2 server configuration parameter APPLHEAPSZ. For example, use 4096.

Description 3

Isolation level TRANSACTION_SERIALIZABLE. If your application uses isolation level TRANSACTION_SERIALIZABLE and uses one of the parameters suggested previously, it might hang while obtaining a connection.

Solution 3

To set an isolation level for a connection, the corresponding connection pool has to be created at that isolation level. See the Sun Java System Application Server Enterprise Edition 8.2 Administration Guide for instructions.