University of Washington
CSE 444
1 Concurrency Control with Locking
1. (20 points)
(a) (5 points) Consider a database with objects X, Y, and Z and assume that there are
two transactions T1 and T2. Transaction T1 reads objects X and Y, writes X, and
commits. Transaction T2 reads objects X and Y, writes object Y. It then reads
object
...[Show More]
1 Concurrency Control with Locking
1. (20 points)
(a) (5 points) Consider a database with objects X, Y, and Z and assume that there are
two transactions T1 and T2. Transaction T1 reads objects X and Y, writes X, and
commits. Transaction T2 reads objects X and Y, writes object Y. It then reads
objects X and Y again, writes X. Finally, it reads object Z, writes it, and commits.
Give three examples of schedules for the transactions T1 and T2 to illustrate each
of the points below:
1. Your schedule should contain a write-read conflict that causes one of the transactions to perform a dirty read.
2. Your schedule should contain a read-write conflict that causes one of the transactions to encounter an unrepeatable read.
3. Your schedule should contain a write-write conflict that causes a lost update.
In each case, your schedule may contain additional conflicts, but should contain
at least one conflict of the type indicated. (In p
[Show Less]