Complete the code to identify the first phase of Two-phase locking (2PL).
In Two-phase locking, the first phase is called the [1] phase where all locks are acquired.The first phase in 2PL is the growing phase where transactions acquire all the locks they need.
Complete the code to identify the second phase of Two-phase locking (2PL).
In Two-phase locking, the second phase is called the [1] phase where all locks are released.The second phase in 2PL is the shrinking phase where transactions release locks and cannot acquire new ones.
Fix the error in the statement about Two-phase locking (2PL).
In 2PL, a transaction cannot acquire new locks during the [1] phase after it has started releasing locks.
In 2PL, once a transaction starts releasing locks (shrinking phase), it cannot acquire new locks. New locks can only be acquired during the growing phase.
Fill both blanks to complete the definition of strict Two-phase locking.
Strict 2PL requires that all [1] locks are held until the [2] of the transaction.
Strict 2PL means all exclusive locks are held until the commit point of the transaction to ensure serializability and recoverability.
Fill all three blanks to complete the explanation of deadlock in 2PL.
Deadlock occurs when two transactions [1] locks that the other [2] and neither can [3].
Deadlock happens when two transactions hold locks that the other requests and neither can proceed, causing a standstill.