January 11, 2005 at 11:02 am
I everybody,
I need to implement a system that informs a user that a record he is browsing on his application was changed by another user, so he knows that it must the reloaded from the database server.
January 12, 2005 at 1:16 am
Hello
I did it in my C++ applications in the following way:
* all records contains a Timestamp type column
* the timestamp is stored in a temporary location while the application reads the record
* the application (in fact, the stored procedure called by the application) re-reads the record just before the update. If the timestamp does not match with the one stored in the temporary location, it means that a user has changed it
* the application then asks what the user want to do: abord record edition he was doing or reload the record changed by the other user
Hope this could fit your needs
Thierry
January 12, 2005 at 1:35 am
Thank you Thierry for your help,
It means that SQL Server doesn't have a mechanism to do it, isn't it ?
I'll try to implement a solution like yours
Best regards
João Miguel
January 12, 2005 at 4:04 am
If you use optemistic locking with ADO, Update raise an exception if the data was changed by another user. You can then show your user the version and decide if overwrite.
Viewing 4 posts - 1 through 3 (of 3 total)
You must be logged in to reply to this topic. Login to reply