Umakanth Srinivasan wrote:
No Iam not performing anything with respect to AutoCommit. I observed that
this problem is related to the isolation level. In MySQL the problem did not
occur. When I checked the default isolation level of MySQL it is
REPEATABLE_READ, in Derby it is READ_COMMITED.
Hope I must have the AUTOCOMMIT set to on.
My only point is that locks are released at commit or rollback and with
AUTOCOMMIT ON a commit is issued at the end of the execution of a
statement. Thus I find using SELECT ... FOR UPDATE ... most effective
with AUTOCOMMIT OFF.