• Courses
  • Tutorials
  • Jobs
  • Practice
  • Contests

Transactions and concurrency control

Question 31

Consider the table R with attributes A, B and C. The functional dependencies that hold on R are : A → B, C → AB. Which of the following statements is/are True ? I. The decomposition of R into R1(C, A) and R2(A, B) is lossless. II. The decomposition of R into R1(A, B) and R2(B, C) is lossy.
  • Only I
  • Only II
  • Both I and II
  • Neither I nor II

Question 32

Which of the following concurrency protocol ensures both conflict serializability and freedom from deadlock? (a)z - phase Locking (b)Time stamp - ordering
  • Both (a) and (b)
  • (a) only
  • (b) only
  • Neither (a) nor (b)

Question 33

Which of the following contains complete record of all activity that affected the contents of a database during a certain period of time?
  • Transaction log
  • Query language
  • Report writer
  • Data manipulation language

Question 34

Which of the following scenarios may lead to an irrecoverable error in a database system?
  • A transaction writes a data item after it is read by an uncommitted transaction
  • A transaction reads a data item after it is read by an uncommitted transaction
  • A transaction reads a data item after it is written by a committed transaction
  • A transaction reads a data item after it is written by an uncommitted transaction

Question 35

Which of the following is correct with respect to Two phase commit protocol?
  • Ensures serializability
  • Prevents Deadlock
  • Detects Deadlock
  • Recover from Deadlock

Question 36

Which of the following is correct ? I.Two phase locking is an optimistic protocol. II. Two phase locking is pessimistic protocol III. Time stamping is an optimistic protocol. IV. Time stamping is pessimistic protocol.
  • I and III
  • II and IV
  • I and IV
  • II and III

Question 37

Let us assume that transaction T1 has arrived before transaction T2. Consider the schedule
S=r1(A); r2(B) ; w2(A); w1(B) 
Which of the following is true?
  • Allowed under basic timestamp protocol.
  • Not allowed under basic timestamp protocols because T1 is rolled back
  • Not allowed under basic timestamp protocols because T2 is rolled back
  • None of these

Question 38

Consider the following schedules involving two transactions. S1: r1 (X) ; r 1 (Y) ; r 2 (X) ; r 2 (Y) ; w 2 (Y) ; w1 (X) S2: r1 (X) ; r 2 (X) ; r 2 (Y) ; w 2 (Y) ; r 1 (Y) ; w1 (X) Which one of the following statements is correct with respect to above ?
  • Both S1 and S 2 is conflict serializable.
  • Both S1 and S2are not conflict serializable.
  • S1 is conflict serializable and S 2 is not conflict serializable.
  • S 1is not conflict serializable and S 2 is conflict serializable.

Question 39

Consider the relation R(P,Q,S,T,X,Y,Z,W) with the following functional dependencies. Consider the decomposition of the relation R into the constituent relations according to the following two decomposition schemes. Which one of the following options is correct?
  • D1 is a lossless decomposition, but D2 is a lossy decomposition
  • D1 is a lossy decomposition, but D2 is a lossless decomposition
  • Both D1 and D2 are lossless decompositions
  • Both D1 and D2 are lossy decompositions

Question 40

Let S be the following schedule of operations of three transactions T1, T2 and T3 in a relational database system:
R2(Y),R1(X),R3(Z),R1(Y)W1(X),R2(Z),W2(Y),R3(X),W3(Z) 
Consider the statements P and Q below:
  • P: S is conflict-serializable.
  • Q: If T3 commits before T1 finishes, then S is recoverable.
Which one of the following choices is correct?
  • Both P and Q are true
  • P is true and Q is false
  • P is false and Q is true
  • Both P and Q are false

There are 48 questions to complete.

Last Updated :
Take a part in the ongoing discussion