When two or more users access a database concurrently, Microsoft SQL Server uses locking to ensure that their actions don't interfere with one another. Locking prevents users from reading data that is being changed by other users, and it prevents users from making more than one change to a record at any one time.
Although SQL Server enforces locking automatically, you can design applications more efficiently by understanding locking and customize locking in your applications.