This preview shows pages 1–3. Sign up to view the full content.
This preview has intentionally blurred sections. Sign up to view the full version.View Full Document
Unformatted text preview: Concurrency Control 175 Serializable Conservative 2PL Strict 2PL 2PL Timestamp W/O TWR Timestamp With TWR Optimistic Multiversion Conflict-serializable Figure 17.3 and on the following update command: replace (salary = 1.1 * EMP.salary) where EMP.ename = ‘Santa’ 1. Give an example of a query that would conﬂict with this command (in a concur- rency control sense) if both were run at the same time. Explain what could go wrong, and how locking tuples would solve the problem. 2. Give an example of a query or a command that would conﬂict with this command, such that the conﬂict could not be resolved by just locking individual tuples or pages but requires index locking. 3. Explain what index locking is and how it resolves the preceding conﬂict. Answer 17.8 Answer omitted. Exercise 17.9 SQL supports four isolation-levels and two access-modes, for a total of eight combinations of isolation-level and access-mode. Each combination implicitly defines a class of transactions; the following questions refer to these eight classes: 1. For each of the eight classes, describe a locking protocol that allows only transac- tions in this class. Does the locking protocol for a given class make any assump- tions about the locking protocols used for other classes? Explain brieﬂy. 176 Chapter 17 2. Consider a schedule generated by the execution of several SQL transactions. Is it guaranteed to be conﬂict-serializable? to be serializable? to be recoverable?guaranteed to be conﬂict-serializable?...
View Full Document
This note was uploaded on 01/17/2012 for the course EGN 4302 taught by Professor Dr.vishak during the Fall '12 term at University of Central Florida.
- Fall '12