Subject | Re: connection setAutoCommit(true) does not auto commit |
---|---|
Author | rrokytskyy@yahoo.co.uk |
Post date | 2001-10-29T08:43:19Z |
> It seems that it does not have any effect for setAutoCommit(true).true :)
> It will not commit even I setAutoCommit(true).
> Is that supposed to be?Not sure. The easiest way to implement autocommit is to change the
FBStatement.execute(String) and add the following after the catch
clause:
finally {
if (c.getAutoCommit())
c.commit();
}
It should work correctly for both managed and unmanaged connections
(in managed connection getAutoCommit() is always false). However,
last time I run jdbc tests from Sun I got few "resource in use" on
commit. So, that is the reason, why the code is not yet in CVS. If
you want you may try changing FBStatement and play a little with it.
Best regards,
Roman Rokytskyy