250+ TOP MCQs on Timestamp based Protocols and Answers

Basic RDBMS Questions and Answers on “Timestamp Based Protocols”.

1. Which of the following cannot be used to implement a timestamp
a) System clock
b) Logical counter
c) External time counter
d) None of the mentioned

Answer: c
Clarification: An external time counter cannot be used to implement a timestamp. System clock and a logical counter can be used.

2. A logical counter is _________ after a new timestamp has been assigned
a) Incremented
b) Decremented
c) Doubled
d) Remains the same

Answer: a
Clarification: A logical counter is incremented after a new timestamp has been assigned everytime.

3. W-timestamp(Q) denotes?
a) The largest timestamp of any transaction that can execute write(Q) successfully
b) The largest timestamp of any transaction that can execute read(Q) successfully
c) The smallest timestamp of any transaction that can execute write(Q) successfully
d) The smallest timestamp of any transaction that can execute read(Q) successfully

Answer: a
Clarification: W-timestamp(Q) denotes The largest timestamp of any transaction that can execute write(Q) successfully.

4. R-timestamp(Q) denotes?
a) The largest timestamp of any transaction that can execute write(Q) successfully
b) The largest timestamp of any transaction that can execute read(Q) successfully
c) The smallest timestamp of any transaction that can execute write(Q) successfully
d) The smallest timestamp of any transaction that can execute read(Q) successfully

Answer: b
Clarification: R-timestamp(Q) denoted the largest timestamp of any transaction that can execute read(Q) successfully.

5. A ________ ensures that any conflicting read and write operations are executed in timestamp order
a) Organizational protocol
b) Timestamp ordering protocol
c) Timestamp execution protocol
d) 802-11 protocol

  250+ TOP MCQs on Join Expressions and Answers

Answer: b
Clarification: A timestamp ordering protocol ensures that any conflicting read and write operations are executed in timestamp order.

6. The default timestamp ordering protocol generates schedules that are
a) Recoverable
b) Non-recoverable
c) Starving
d) None of the mentioned

Answer: b
Clarification: The timestamp ordering protocol generates schedules that are non-recoverable. But it can be extended to make the schedules recoverable.

7. State true or false: The Thomas write rule has a greater potential concurrency than the timestamp ordering protocol
a) True
b) False

Answer: a
Clarification: The Thomas write rule has a greater potential concurrency than the timestamp ordering protocol. This is because it is a modified version of the timestamp ordering protocol in which obsolete write operations can be ignored under certain circumstances.

8. Which of the following timestamp based protocols generates serializable schedules?
a) Thomas write rule
b) Timestamp ordering protocol
c) Validation protocol
d) None of the mentioned

Answer: a
Clarification: Thomas write rule protocol generates serializable schedules that no other protocol can generate.

9. In timestamp ordering protocol, suppose that the transaction Ti issues read(Q) and TS(Ti)<W-timestamp(Q), then
a) Read operation is executed
b) Read operation is rejected
c) Write operation is executed
d) Write operation is rejected

Answer: b
Clarification: Suppose that transaction Ti issues read(Q). If TS(Ti ) < W-timestamp(Q), then Ti needs to read a value of Q that was already overwritten. Hence, the read operation is rejected, and Ti is rolled back.

10. In timestamp ordering protocol, suppose that the transaction Ti issues write(Q) and TS(Ti)<W-timestamp(Q), then
a) Read operation is executed
b) Read operation is rejected
c) Write operation is executed
d) Write operation is rejected

  250+ TOP MCQs on SQL Data definition and Answers

Answer: d
Clarification: In timestamp ordering protocol, suppose that the transaction Ti issues write(Q) and TS(Ti)<W-timestamp(Q), then the value of Q that Ti is producing was needed previously, and the system assumed that the value would never be produced. Hence the system rejects the write(Q) operation and the transaction Ti rolls back.

Leave a Comment

Your email address will not be published. Required fields are marked *

Scroll to Top