Question:

Consider concurrent execution of two transactions \(T_1\) and \(T_2\) in a DBMS, both of which access a data object \(A\). For these two transactions to not conflict on \(A\), which one of the following statements must be true?

Show Hint

A conflict needs at least one write among the two operations; two transactions that only read the same item never conflict, but any pairing with a write does.
Updated On: Jul 22, 2026
  • Both \(T_1\) and \(T_2\) only read \(A\)
  • \(T_1\) reads \(A\) and \(T_2\) writes \(A\)
  • \(T_1\) writes \(A\) and \(T_2\) reads \(A\)
  • Both \(T_1\) and \(T_2\) write \(A\)
Show Solution
collegedunia
Verified By Collegedunia

The Correct Option is A

Solution and Explanation

Step 1: Recall the definition of a conflict between two operations on the same data item.
Two operations from different transactions on the same data object conflict if at least one of them is a write, and the order in which they run can change the outcome. The three conflicting pairs are write-write, read-write, and write-read. The only pair that never conflicts is read-read.

Step 2: Explain why read-read never conflicts.
If both transactions only read A, neither of them changes the value of A. Reading a value does not modify it, so no matter which transaction reads first, both see the exact same value of A, and neither transaction's outcome, nor A's final value, depends on the order of the two reads. There is nothing to conflict over.

Step 3: Explain why any pairing that includes a write does conflict.
If one transaction writes A, what the other transaction sees, if it reads A, or produces, if it also writes A, depends on the relative order of the operations. A read after a write sees the updated value, a read before a write sees the old value, and two writes in different orders can leave different final values in A. Because the outcome changes with the order, these are exactly the pairs a DBMS must control using locking or scheduling: read-write, write-read, and write-write.

Step 4: Eliminate the other options.
Option (B), \(T_1\) reads and \(T_2\) writes A, is a read-write conflict since order matters. Option (C), \(T_1\) writes and \(T_2\) reads A, is the same read-write conflict in the other direction. Option (D), both write A, is a write-write conflict since the final stored value depends on which write happens last. All three involve at least one write, so all three conflict.

Step 5: Conclusion.
The only case where \(T_1\) and \(T_2\) are guaranteed not to conflict on A is when both of them only read A.

Final Answer:
Both \(T_1\) and \(T_2\) only read A. \[ \boxed{\text{Option (A)}} \]
Was this answer helpful?
0
0

Top GATE CS Databases Questions

View More Questions