Multi users editing a database
I am developing a system in which there will be several users accessing and editing records in a SQL database.
I want to study more about the solutions for the integrity of the information, and I don't know where to start.
My concern now is about the situation where 2 or more users might be editing the same record at the same time.
Where and how should I lock that record? In the ASP code or in the database?
What if the user who has the record locked for his/her edition, all of a sudden turns the computer off without submiting the transaction?
Could you point the direction where I should look for more information?
Thanks
Re: Multi users editing a database
Quote:
Originally posted by atimo
Where and how should I lock that record? In the ASP code or in the database?
You would lock the record in the ASP code itself. You have about 4 lock options, read this page for the specifics.
Quote:
What if the user who has the record locked for his/her edition, all of a sudden turns the computer off without submiting the transaction?
Eventually, it will time out and the records will be free again.