Lock-Based Protocols A lock is a mechanism to control concurrent access to a data item Data items can be locked in two modes 1.exclusive ()mode.Data item can be both read as well as written.X-lock is requested using lock-X instruction. 2.shared(S)mode.Data item can only be read.S-lock is requested using lock-S instruction. Lock requests are made to the concurrency-control manager by the programmer.Transaction can proceed only after request is granted. Database System Concepts-6th Edition 15.3 @Silberschatz,Korth and SudarshanDatabase System Concepts - 6 15.3 ©Silberschatz, Korth and Sudarshan th Edition Lock-Based Protocols A lock is a mechanism to control concurrent access to a data item Data items can be locked in two modes : 1. exclusive (X) mode. Data item can be both read as well as written. X-lock is requested using lock-X instruction. 2. shared (S) mode. Data item can only be read. S-lock is requested using lock-S instruction. Lock requests are made to the concurrency-control manager by the programmer. Transaction can proceed only after request is granted