|
-----Original Message-----
From: midrange-l-bounces@xxxxxxxxxxxx [mailto:midrange-l-
bounces@xxxxxxxxxxxx] On Behalf Of James H. H. Lampert
Sent: Friday, October 25, 2013 7:25 PM
To: midrange-l
Subject: JDBC record locking -- help?
In my JDBCR4 project, I thought I'd gotten rid of an issue with
undesired record locking in a CONCUR_UPDATABLE TYPE_SCROLL_SENSITIVE
result set.
But I was wrong.
The idea is to hold the result set, but not lock any record until
actually ready to update it.
I thought I could avoid record locks by positioning the result set's
cursor to "beforeFirst" or "afterLast." But it seems that even though
that theoretically places the cursor "not on a record," in practice, I'm
still holding a record lock.
I just now verified that the same thing happens when accessing the file
from Java, and worse, that the lock on the "current record" also remains
active if I "moveToInsertRow()."
I'd rather not have to open the main result set as CONCUR_READ_ONLY,
then open a separate CONCUR_UPDATABLE result set when I want the
record
lock, but it's beginning to look like I'm stuck with exactly that,
unless there's some way through JDBC to get CONCUR_UPDATABLE result
set
to release its lock without closing it outright.
--
JHHL
--
This is the Midrange Systems Technical Discussion (MIDRANGE-L) mailing list
To post a message email: MIDRANGE-L@xxxxxxxxxxxx
To subscribe, unsubscribe, or change list options,
visit: http://lists.midrange.com/mailman/listinfo/midrange-l
or email: MIDRANGE-L-request@xxxxxxxxxxxx
Before posting, please take a moment to review the archives
at http://archive.midrange.com/midrange-l.
As an Amazon Associate we earn from qualifying purchases.
This mailing list archive is Copyright 1997-2025 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].
Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.