Skip to content
GATEiit

GATE CSE 2017 Session 2 Q54: Number of conflict serializable schedules of two transactions

Syllabus topic: Transactions and concurrency control

Question

Two transactions T1 and T2 are given as

T1:r1(X) w1(X) r1(Y) w1(Y)

T2:r2(Y) w2(Y) r2(Z) w2(Z)

where ri(V) denotes a read operation by transaction Ti on a variable V and wi(V) denotes a write operation by transaction Ti on a variable V. The total number of conflict serializable schedules that can be formed by T1 and T2 is ________.

Try it: numerical answer: type the value

Numerical answer. No negative marking.
Show answer and explanation

Answer: 54 (official GATE 2017 final answer key)

Concept used: A schedule of two transactions is conflict serializable iff all conflicting pairs (here only the operations on Y) are ordered the same way, so it is conflict equivalent to T1T2 or T2T1.

Concept notes

Loading notes…

First step: Count interleavings equivalent to T1T2 (all of T1's Y operations before T2's) and to T2T1 (w2(Y) before r1(Y)) separately, then add.

Full step-by-step solution

Loading…

Answer from the official final answer key. Found a mistake? Use Report issue and we will fix it.

More questions on Transactions and concurrency control

Every PYQ on this topic →

Share this question

WhatsAppDownload image

Source: official GATE 2017 Session 2 CS question paper and final answer key, organised by IIT Roorkee. Question paper · Answer key