CS FundamentalsVery hardGATE CS · Product placement
TS(T1) = 15, TS(T2) = 30, TS(T3) = 25; all read/write timestamps start at 0. Under basic timestamp ordering with Thomas's write rule, which operation of the schedule W2(B), W3(A), W1(B), W2(A), R3(A), R2(A), R1(A), W1(A) is the first to make its transaction roll back?
- A. R3(A) (operation 5)
- B. No operation is rejected
- C. W1(A) (operation 8)
- D. R1(A) (operation 7)
Correct answer: A. R3(A) (operation 5)
Track read-TS and write-TS of each item. R3(A) (operation 5) is the first operation that violates the protocol (a read of a value with a newer write-TS, or a write after a newer read or write). Earlier, W1(B) (operation 3) was an obsolete write and is simply ignored under Thomas's rule instead of causing a rollback.
More DBMS and SQL questions
- R(A, B, C, D, E) with functional dependencies B → AD, AC → B, A → B is decomposed into R1(A, B), R2(B, D), R3(B, C, E). Which statement is…
- R(A, B, C, D, E, F) has functional dependencies A → CD, CF → A, E → B, D → A. Which of these attribute sets is NOT a superkey of R?
- Table Product(pid, cat, price) rows: (1, 'X', 10), (2, 'X', 20), (3, 'Y', 20), (4, NULL, 30), (5, 'Y', NULL), (6, 'Z', 5). What does this…
- Consider the schedule R3(A), R2(A), R3(B), W3(B), R2(B), W1(B), W1(A), R1(A). Which statement is correct?
- T1: R1(A), R1(B) and T2: W2(A), W2(B). Of all 6 interleavings that keep each transaction's own order, how many are conflict serializable?
- Σ = {CD → A, AC → B, B → E, D → B, C → D} on R(A, B, C, D, E). Exactly one FD in Σ is redundant (it can be derived from the others). Which…