Locking a DB while updating...

B

Bucko

How important do you guys feel locking a database is while
updating/adding information? Do you do it with every app you make? Only
very high volume (traffic) apps? I'm trying to decide if my app needs it.
 
G

George Ter-Saakov

Not clear what do you mean by "updating/adding information".
If you are changing the database/tables structure then I would bring the IIS
down for that period of time.

But if you are updating/inserting records then there is no universal
solution. You should use appropriate Transaction level and it all depends on
the nature of your updates.

But you do not need to lock the database/tables. Only the updated records.


George.
 
J

Jan Limpens

probably your app doesn't need it, as you are asking yourself. when you
need it, you will know ;)
 
A

Alvin Bruney

You don't lock a database because you force every thing touching the data
base to wait. Lock the row you want to adjust. I believe this is only
available in informix, otherwise lock the page.
Set lock mode to wait will do the trick for row level locking
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
474,430
Messages
2,571,676
Members
48,796
Latest member
Greg L.

Latest Threads

Top