Help Please !! Optimistic Lock question... 
Author Message
 Help Please !! Optimistic Lock question...

How to check if there is any user currently editing a record on other
machine ?

My Idea is this:

Using Visual Basic 5.0. DAO, Microsoft Access Database.

Set OPTIMISTIC LOCK for database editing. Then if any user wants to edit
a record, check if record is not under editing by other user on the
network. If the record is under edition I will warn user about it.

Any Ideas ?

Thanks in Advance

Charlie



Tue, 06 Mar 2001 03:00:00 GMT  
 Help Please !! Optimistic Lock question...
I think this can only be done by pessimistic locking. From the DAO helpfile:

You can use the LockEdits property with dynaset- and table-type Recordset objects and with the outdated Dynaset
and Table objects.
If a page is locked, no other user can edit records on the same page.  If you set LockEdits to True and another
user already has the page locked, an error occurs when you use the Edit method.  Other users can read data from
locked pages.
If you set LockEdits to False and later use Update while the page is locked by another user, an error occurs.  To
see the changes made to your record by another user (and lose your changes), set the Bookmark property of your
Recordset object to itself.


Quote:
> How to check if there is any user currently editing a record on other
> machine ?

> My Idea is this:

> Using Visual Basic 5.0. DAO, Microsoft Access Database.

> Set OPTIMISTIC LOCK for database editing. Then if any user wants to edit
> a record, check if record is not under editing by other user on the
> network. If the record is under edition I will warn user about it.

> Any Ideas ?

> Thanks in Advance

> Charlie




Wed, 07 Mar 2001 03:00:00 GMT  
 
 [ 2 post ] 

 Relevant Pages 

1. Help please !!.. OPTIMISTIC LOCK Question...

2. Add a new item also locked with optimistic locking

3. Help needed : ServerSide Cursor and Optimistic Locking

4. PLEASE HELP, PLEASE HELP, PLEASE HELP, PLEASE HELP, PLEASE HELP, PLEASE HELP, PLEASE HELP,

5. Optimistic Lock: No Error Adding New Record

6. Optimistic Locking and Write Conflict Errors

7. Optimistic Locking in VB with Stored procedures

8. Optimistic Record locking (networked Database)

9. Re : Error 3186 on Optimistic Locking

10. Error 3186 on Optimistic Locking

11. Dynamic cursor + Optimistic batch locking

12. IOT and Optimistic Locks

 

 
Powered by phpBB® Forum Software