|
Problem |
SetAutoCommit() on a connection obtained from a XA Data
Source in WebSphere® Application Server returns an exception. An example
exception for Oracle is:
java.sql.SQLException: Use explicit XA call. For DB2® an example
exception is: CLI0126E Operation invalid at this time. |
|
Cause |
The application gets the connection from a XA data source,
the method setAutoCommit() on the connection can be set if only one
resource is involved in the transaction. However, if more than one
resource is involved in the transaction, it is not permitted. The JDBC™
drivers may give an exception when autocommit is set on the
connection. |
|
Solution |
Add an explicit commit() to the application code. |
|
|
|
|
|
|