Last Updated : 29 Nov, 2018

Consider the following statements:

  • (i) Wound-wait always outperforms wait-die.
  • (ii) If we know all records that each transaction will access, we can prevent deadlocks by imposing a total order on lock acquisitions.
  • (iii) Wait-die always outperforms wound-wait.
  • (iv) In general, locking uses fewer resources than optimistic methods that rely on validation.

Which of following option is correct?
(A) Only (ii) and (iv) are correct
(B) Only (iii) and (iv) are correct
(C) Only (ii) and (iii) are correct
(D) Only (i) and (iii) are correct


Answer: (A)

Explanation: It is hard to tell which scheme is better, because, Wait-die has more roll backs; but the transactions have perform little to no work and Wound-wait has less roll backs; but the transaction that got aborted has done some work.

Only statement (ii) and (iv) are correct.

Option (A) is true.

Quiz of this Question


Share your thoughts in the comments