RDBMS MCQ set number 00653

1. ________ deletes a data item from a database
a) Delete(Q)
b) Insert(Q)
c) Drop(Q)
d) None of the mentioned

Answer

Answer: a [Reason:] Delete(Q) deletes a data item from a database. Insert(Q) inserts a new data item Q into the database and assign Q an initial value.

2. Which of the following does not lock the entire index
a) Phantom locking
b) Phantom problem
c) Index locking
d) Index problem

Answer

Answer: c [Reason:] Index locking avoids locking the entire index. Any transaction that inserts a tuple into a relation must insert information into every index maintained on the relation.

3. Which of the following is included in the operational mechanism of the index locking protocol?
a) Every transaction must have at least one index
b) A transaction that performs a lookup must acquire a shared lock on all the index leaf nodes that it accesses
c) The rule of the two phase locking mechanism must be observed
d) All of the mentioned

Answer

Answer: d [Reason:] The operational mechanism of the index locking protocol includes, every transaction must have at least one index. A transaction that performs lookup must acquire a shared lock on all the index leaf nodes that it accesses. The rule of the two phase locking mechanism must be followed.

4. _________ is a form of two degree consistency designed for programs that iterate over tuples of a relation by using cursors.
a) Cursor stability
b) Serializability
c) Non-serializability
d) Predicate locking

Answer

Answer: a [Reason:] Cursor stability is a form of two degree consistency designed for programs that iterate over tuples of a relation by using cursors. It ensures that the tuple that is currently being processed is locked in shared mode and any modified tuples are locked in exclusive mode until the transaction commits.

5. Transactions that involve user interactions are called __________
a) Validations
b) Conversations
c) Interfaces
d) None of the mentioned

Answer

Answer: b [Reason:] Transactions that involve user interactions are called as conversation. These are named differently to differentiate them from regular transactions. Validation using version numbers is very useful for such transactions.

6. State true or false: Key value locking provides increased concurrency
a) True
b) False

Answer

Answer: a [Reason:] Key value locking provides increased concurrency. Using key value improperly however might cause phantom phenomenon to occur.

7. To prevent the phantom phenomenon, _______ is used
a) Key value locking
b) Next key locking
c) Previous key locking
d) None of the mentioned

Answer

Answer: b [Reason:] The failure of a system to prevent a non serialized tuple when two transactions conflict with each other is called as phantom phenomenon. To prevent the phantom phenomenon, the next key locking is used.

8. Which of the following does cursor stability ensure
a) The tuple that is currently being processed by the iteration is locked in shared mode
b) The tuple that is currently being processed is not locked in shared mode
c) Any modified tuples are not locked in exclusive mode
d) None of the mentioned

Answer

Answer: a [Reason:] Cursor stability ensures that the tuple that is currently being processed by the iteration is locked in shared mode and any modified tuples are locked in exclusive mode until the transaction commits.

9. State true or false: Exclusive locks are held until transaction commit in degree two consistency
a) True
b) False

Answer

Answer: a [Reason:] Exclusive locks are held until transaction commit in degree two consistency, no transaction can read an uncommitted value.

ed010d383e1f191bdb025d5985cc03fc?s=120&d=mm&r=g

DistPub Team

Distance Publisher (DistPub.com) provide project writing help from year 2007 and provide writing and editing help to hundreds student every year.