GATE 2014 CS (CS3) – Question 39
Transactions:
T1: r1(X); r1(Z); w1(X); w1(Z)
T2: r2(Y); r2(Z); w2(Z)
T3: r3(Y); r3(X); w3(Y)
Schedules:
S1: r1(X); r3(Y); r3(X); r2(Y); r2(Z); w3(Y); w2(Z); r1(Z); w1(X); w1(Z)
S2: r1(X); r3(Y); r2(Y); r3(X); r1(Z); r2(Z); w3(Y); w1(X); w2(Z); w1(Z)
Which statement is TRUE?
Practise this question in The GATE Grind →
Show answer and explanation
Correct answer: (A) Only S1 is conflict-serializable
Explanation
S1has edges T2→T3throughY,T3→T1throughXandT2→T1throughZ, an acyclic order T2,T3,T1. InS2, r1(Z)beforew2(Z)createsT1→T2while r2(Z)beforew1(Z)createsT2→T1. Hence **onlyS1,A** is conflict serializable.