ACID properties (Atomicity, Consistency, Isolation, Durability) MCQs in DBMS
By: Prof. Dr. Fazal Rehman | Last updated: September 23, 2024
Which ACID property ensures that a transaction is treated as a single unit of work, meaning it either fully completes or fully fails?
a) Atomicity
b) Consistency
c) Isolation
d) DurabilityAnswer: a) Atomicity
Which ACID property ensures that a database remains in a valid state before and after a transaction?
a) Atomicity
b) Consistency
c) Isolation
d) DurabilityAnswer: b) Consistency
Which ACID property guarantees that concurrent execution of transactions will result in a system state that would be obtained if transactions were executed serially?
a) Atomicity
b) Consistency
c) Isolation
d) DurabilityAnswer: c) Isolation
Which ACID property ensures that once a transaction has been committed, it will remain committed even in the event of a system failure?
a) Atomicity
b) Consistency
c) Isolation
d) DurabilityAnswer: d) Durability
What does the Atomicity property ensure in the context of a transaction?
a) Transactions are executed in a way that maintains database consistency.
b) All operations of a transaction are completed, or none are executed.
c) Transactions do not interfere with each other’s execution.
d) Changes made by a transaction are permanent even after a failure.Answer: b) All operations of a transaction are completed, or none are executed.
If a transaction causes an update to a database that cannot be rolled back, which ACID property is at risk?
a) Atomicity
b) Consistency
c) Isolation
d) DurabilityAnswer: a) Atomicity
Which ACID property would be violated if a transaction read data that was modified by another concurrent transaction but not yet committed?
a) Atomicity
b) Consistency
c) Isolation
d) DurabilityAnswer: c) Isolation
Which mechanism is often used to implement the Isolation property in a database system?
a) Checkpoints
b) Two-phase commit protocol
c) Locking and concurrency control
d) Redundant arrays of independent disks (RAID)Answer: c) Locking and concurrency control
What does the Durability property ensure about a transaction’s effects?
a) They are temporary until confirmed by the user.
b) They are rolled back if a failure occurs.
c) They are preserved and not lost due to system failures.
d) They are subject to being overridden by other transactions.Answer: c) They are preserved and not lost due to system failures.
Which of the following scenarios demonstrates a failure to uphold the Consistency property?
a) A transaction that successfully commits after ensuring no conflicting updates
b) A transaction that fails to complete, but all its operations are rolled back
c) A transaction that leaves the database in a state where constraints are violated
d) A transaction that ensures its changes are visible to all subsequent transactionsAnswer: c) A transaction that leaves the database in a state where constraints are violated
In a DBMS, how can Durability be ensured?
a) By using rollback segments
b) By maintaining transaction logs and ensuring that changes are written to non-volatile storage
c) By using isolation levels to control visibility of transaction changes
d) By employing deadlock detection mechanismsAnswer: b) By maintaining transaction logs and ensuring that changes are written to non-volatile storage
Which ACID property is tested when verifying that a transaction does not interfere with other concurrently executing transactions?
a) Atomicity
b) Consistency
c) Isolation
d) DurabilityAnswer: c) Isolation
What happens if the Atomicity property is not properly implemented during a transaction?
a) The database may remain in an inconsistent state.
b) Data loss may occur in the event of a system failure.
c) Concurrent transactions may affect each other.
d) Transactions may not be logged correctly.Answer: a) The database may remain in an inconsistent state.
Which DBMS component helps in implementing the Consistency property?
a) Recovery manager
b) Concurrency control manager
c) Transaction manager
d) Log managerAnswer: b) Concurrency control manager
Which type of failure primarily tests the Durability property of a database?
a) System crash
b) Application bug
c) Data entry error
d) Network failureAnswer: a) System crash