Gossamer Forum
Home : Products : DBMan : Installation :

Record Locking

Quote Reply
Record Locking
Hello,

Has anybody figured out how to lock a record so that no two users can delete each others modifications?

ex: I have users Joe and Bill
1. Joe selects record 45 to modify the field "Comment"
2. Bill also selects record 45 to modify field "Heading"
3. Joe clicks on the "Modify Record"
4. Bill click on the "Modify Record"

The Problem here is that since Bill queried the record before Joe made the modification, whatever Joe modified will be deleted by Bill.

The only thing I can think of, is to add another field with a complete timestamp of when the record was last modified. I would then check if the timestamp has changed while the user was doing a modification and raise an error if so.

Any other ideas on how to go around this?

Cheers
-JO


[This message has been edited by Jaime Ortega (edited April 07, 1999).]
Quote Reply
Re: Record Locking In reply to
Are you allowing users to modify records other than their own? That seems like a dangerous practice to me.


------------------
JPD