Recall & Review
beginner
What is a transaction in a database?
A transaction is a sequence of one or more database operations that are treated as a single unit. It must be completed fully or not at all to keep data consistent.
Click to reveal answer
beginner
Name the five main states of a database transaction.
The five main states are: Active, Partially Committed, Committed, Failed, and Aborted.
Click to reveal answer
beginner
What happens in the Active state of a transaction?
In the Active state, the transaction is executing its operations but has not yet completed all its tasks.
Click to reveal answer
intermediate
Explain the difference between Committed and Aborted states.
Committed means the transaction has completed successfully and changes are saved permanently. Aborted means the transaction failed and all changes are undone to keep data safe.
Click to reveal answer
intermediate
What is the Partially Committed state in a transaction?
Partially Committed is the state after a transaction has executed all its operations but before the changes are permanently saved.
Click to reveal answer
Which transaction state means the transaction is currently running?
✗ Incorrect
The Active state means the transaction is executing its operations.
What state follows after a transaction completes all its operations but before saving changes?
✗ Incorrect
Partially Committed is the state after all operations are done but before changes are saved.
If a transaction fails and undoes all changes, what state does it enter?
✗ Incorrect
Aborted means the transaction failed and rolled back all changes.
Which state indicates that changes made by a transaction are permanently saved?
✗ Incorrect
Committed means the transaction completed successfully and changes are saved.
What is the first state of a transaction?
✗ Incorrect
The transaction starts in the Active state when it begins execution.
Describe the sequence of states a transaction goes through from start to successful completion.
Think about what happens when a transaction starts, finishes operations, and saves changes.
You got /3 concepts.
Explain what happens when a transaction fails and how the database maintains consistency.
Consider how the system handles errors to keep data safe.
You got /4 concepts.