Skip to content
Official PYQ · 2003

GATE CS 2003 Q29 — Transactions and Concurrency Control

Explain with AI

Which of the following scenarios may lead to an irrecoverable error in a database system?

Choose one option
View worked solution

Answer: D

A schedule is recoverable if, for each pair of transactions TiT_i and TjT_j such that TjT_j reads a data item previously written by TiT_i, the commit operation of TiT_i appears before the commit operation of TjT_j.

If TjT_j reads a value written by an uncommitted transaction TiT_i (known as a dirty read) and commits before TiT_i commits, the schedule becomes irrecoverable. If TiT_i subsequently aborts, the database cannot roll back the already-committed TjT_j, violating the atomicity and durability properties.

Analyzing the Options:

  • Option A: A transaction writes a data item after it is read by an uncommitted transaction (Write-After-Read). This does not create a dependency that affects recoverability.
  • Option B: A transaction reads a data item after it is read by an uncommitted transaction (Read-After-Read). Read operations do not conflict or modify data, so this is completely safe.
  • Option C: A transaction reads a data item after it is written by a committed transaction. Since the writing transaction is already committed, there is no risk of it aborting, making this scenario perfectly safe.
  • Option D: A transaction reads a data item after it is written by an uncommitted transaction. This is a dirty read. If the reading transaction commits before the writing transaction, it leads to an irrecoverable error.

Free practice · Your answers on this page are not saved.

Published
Report a correction
Keep exploringMore Transactions and Concurrency Control questions