Hi there,
we have the following problem using a DB2 version 7 on z/OS, referring
also <a
href="http://groups.google.de/group/comp.databases.ibm-db2/browse_thread/thread/2555018c0d364314/ea946c98e25ce4b7?lnk=gst&q=assmann&rnum=2#ea946c98 e25ce4b7">this
thread</a>:
Using a java program with a connection to a DB2 using a type 2-driver,
we insert many datasets into the database in one transaction. The type
2-driver connects to the database using RRSAF. If the program will be
killed (e.g. by using a kill -9 command), the program itself terminats
- but the transaction will be committed. Important is, that the program
did not send any commit command using the jdbc-connection (which cannot
be done by the program because it was killed toughly so the code
sending a rollback or commit will not be reached).
If we use a type 4-driver (which does not connect to the database using
RRSAF), everything works well. The connection will be closed doing a
rollback before. Unfortunately, it is necessary for us to use a type
2-driver, the explanation of this should not be part of this thread and
should not be discussed.
Does anyone has an idea how to solve this problem, doing a implicit
rollback closing a connection? Is there a parameter on the DB2 using
RRSAF where could be set that the database has to do a rollback while
closing a connection? A commit should only be done if the program
explicitly sends the commit-command, not at any time an implicit
commit.
We are looking forward to hearing from you soon.
Best regards,
Ralf