Computer Sciences > GATE 2025 SET-2 > Concurrency Control
Consider the database transactions T1 and T2, and data items X and Y. Which of the schedule(s) is/are conflict serializable?
A
R1(X), W2(X), W1(Y), W2(Y), R1(X), W1(X), COMMIT(T2), COMMIT(T1)
B
W2(X) R1(X) W2(Y) W1(Y) R1(X) COMMIT(T2) W1(X) COMMIT(T1)
C
R1(X) W2(X) W1(Y) W2(Y) R1(X) W1(X) COMMIT(T1) COMMIT(T2)
D
W2(X) R1(X) W1(Y) W2(Y) R1(X) COMMIT(T2) W1(X) COMMIT(T1)

Correct : b

The correct answer is Option B.
To figure out which schedule is conflict serializable, we use the precedence graph (also called a serialization graph). The idea is straightforward — if two operations from different transactions conflict with each other (meaning they access the same data item and at least one of them is a write), we draw a directed edge from the transaction whose operation comes first. If this graph ends up having a cycle, the schedule is not conflict serializable. If there's no cycle, it is.
Two operations conflict when — they belong to different transactions, they access the same data item (X or Y in this case), and at least one of them is a Write. So R1(X) and W2(X) conflict. W1(Y) and W2(Y) also conflict. You get the idea.
Now let's walk through Option B:
W2(X) → R1(X): T2 writes X before T1 reads it → edge from T2 to T1
W2(Y) → W1(Y): T2 writes Y before T1 writes it → edge from T2 to T1
Both edges go from T2 → T1. There is no edge going back from T1 to T2, so the graph has no cycle. This means Schedule B is conflict serializable — it is equivalent to the serial schedule T2 → T1.
For the other options (A, C, D), when you build their precedence graphs, you'll find edges going in both directions between T1 and T2 — forming a cycle — which means they cannot be transformed into any serial schedule and are therefore not conflict serializable.
A quick tip worth remembering — conflict serializability is a stronger condition than view serializability. Every conflict serializable schedule is view serializable, but not the other way around. So when GATE asks about conflict serializability specifically, always go with the precedence graph approach, it's the most reliable and fastest method.

Similar Questions

A schedule of three database transactions T1, T2, and T3 is shown.Ri(A) and Wi(A) denote read and write of data item A by transaction Ti,i=1,2,3.The transaction...
#1358 MCQ
A palindrome is a word that reads the same forwards and backwards. In a game of words, a player has the following two plates painted with letters. From...
#1 MCQ
Which number does not belong in the series below? 2, 5, 10, 17, 26, 37, 50, 64
#4 MCQ

Related Topics

conflict serializable schedule GATE CS 2025 GATE 2025 Set-2 DBMS GATE question concurrency control precedence graph transaction serializability database transactions T1 T2 schedule conflict operations DBMS GATE computer science

Unique Visitor Count

Total Unique Visitors

Loading......