Confusion with LockType 
Author Message
 Confusion with LockType

I have thoroughly confused myself with respect to what LockType does  - When
I create an ADO recordset from an Oracle database, I am trying to figure out
what LockType does.  Does it affect the recordset itself or the underlying
Oracle records?

My goal is to open a static recordset and lock the underlying Oracle
records, disconnect the recordset, do some changes, etc, then reconnect and
do a batch update.  I don't want anyone to be able to change the records
while the user is working on them.  I was hoping I could use the LockType to
lock the underlying Oracle records.

Any ideas out there on this subject would be very welcome.  Thanks

Dan Hillman



Mon, 28 Jun 2004 06:59:04 GMT
 Confusion with LockType

Dan, I apologize.  I replied to your email instead of the group by mistake.

Locking affects the underlying records, usually a single record at a time is
locked (in some cases it depends on the number of records in a datapage).
The following is pretty standard, no matter what database.
Optimisitc    -> the lock request will be issued when you try to update the
record.
Pessimistic -> the lock request is issued when you start to edit the record.

As soon as you Disconnect from the database all Locks are dropped.   I doubt
if there is a provider or database out there that will do what you want,
meaning you will have to come up with your own method.

Bruce


Quote:
> I have thoroughly confused myself with respect to what LockType does  -
When
> I create an ADO recordset from an Oracle database, I am trying to figure
out
> what LockType does.  Does it affect the recordset itself or the underlying
> Oracle records?

> My goal is to open a static recordset and lock the underlying Oracle
> records, disconnect the recordset, do some changes, etc, then reconnect
and
> do a batch update.  I don't want anyone to be able to change the records
> while the user is working on them.  I was hoping I could use the LockType
to
> lock the underlying Oracle records.

> Any ideas out there on this subject would be very welcome.  Thanks

> Dan Hillman



Mon, 28 Jun 2004 08:50:44 GMT
 
 [ 2 post ] 

 Relevant Pages 

1. AppendChunk and OpenResultset - what is best locktype?

2. Curser type value and LockType values

3. VB 6 (MSRDC.locktype) and SQL 6.5 (ODBC)

4. Update_page_blk locktype

5. Cursors and LockTypes.

6. LockType parameter error while calling the Update Method

7. ADO & Locktype for Command.Execute method

8. Update_page_blk locktype

9. AppendChunk and OpenResultset - what is best locktype?

10. ADO, ASP, Deadlocks : Locktype?

11. Problem with ADO Locktypes for Recordsets

12. Cursors and LockTypes.


 
Powered by phpBB® Forum Software