Summary

Following are important notes to remember when addressing multiuser issues in SQL Server:

  • Locks are used to maintain data consistency in a multiuser environment.

  • Excessive locking can lead to blocking.

  • Blocking occurs when a process must wait for another process to complete.

  • Deadlock occurs when two users have locks on separate objects and each user is trying to lock the other user's objects.

  • Use the Enterprise Manager, Performance Monitor, SQL Server Profiler, system procedures (sp_who, sp_lock), and trace flags to diagnose blocking and locking issues.

  • Almost every SQL operation against a table results in some sort of lock.

  • Row and page locks are generally preferred to table locks because they are less likely to cause blocking.

  • Read statements ...

Get Microsoft® SQL Server™ 2000 DBA Survival Guide, Second Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.