ACID Properties in DBMS Explained: Concepts and a Worked Transaction
Build atomicity, consistency, isolation, and durability from one 1,500-unit transfer. Trace failures before and after commit, then classify common question clues.
KnowledgeGate Team
Exam prep & CS education

ACID is easy to expand as an acronym. The real difficulty begins when a question describes a crash, a constraint violation, or two overlapping transactions without naming the relevant property. A single transaction illustrates all four guarantees, with distinct clues identifying each one.
1. Start with the transaction boundary
A transaction is one logical unit of database work, not necessarily one SQL statement. It starts at a boundary such as BEGIN, performs reads and writes, and finishes with either COMMIT or ROLLBACK. Commit accepts the unit as a whole. Rollback removes its uncommitted effects.
Consider its stable lifecycle:
Active: its statements are running.
Partially committed: its last statement has run, but the commit is not yet safely completed.
Committed: the transaction has completed successfully.
Failed: an error or failure prevents further progress.
Aborted: rollback has restored the database from that incomplete attempt.
One transaction boundary is enough to isolate the four ACID guarantees. The Transaction Management in DBMS guide carries the topic into serializability, locking, timestamps, and crash recovery, while CS Fundamentals for Exams and Placements places that reasoning in the wider subject map.
2. ACID is four different promises
Atomicity means all operations in the transaction take effect, or none do.
Consistency means a successful transaction preserves declared integrity rules.
Isolation means concurrent execution does not expose an invalid intermediate view and behaves according to the database's isolation guarantee.
Durability means an acknowledged commit survives a later failure.
Property | Question to ask | Typical failure clue |
|---|---|---|
Atomicity | Did the complete unit happen? | Partial work remains instead of being rolled back |
Consistency | Are all declared rules still true? | A constraint or invariant is violated |
Isolation | Did overlap reveal or corrupt in-progress work? | Another transaction observes or overwrites unfinished work |
Durability | Did committed results persist? | Acknowledged work disappears after a crash |
The properties cooperate, but they are not synonyms. Atomicity says what happens to an incomplete unit. Durability says what happens to a completed one.
3. Worked example: transfer 1,500 units without breaking the database
Account A begins with 10,000 units and account B with 4,000 units. The conserved total is:
A + B = 10,000 + 4,000 = 14,000
Transaction T1 transfers 1,500 units from A to B:
BEGINT1.Read A as 10,000.
Calculate
10,000 - 1,500 = 8,500.Write A = 8,500.
Read B as 4,000.
Calculate
4,000 + 1,500 = 5,500.Write B = 5,500.
COMMITT1.
The final check is 8,500 + 5,500 = 14,000.
Atomicity binds the two writes together. Consistency requires the total to remain 14,000 and the constraint A >= 0 to hold. Isolation prevents another transaction from treating the half-finished pair as a valid view. Durability retains A = 8,500 and B = 5,500 after commit, even if a later failure occurs.

4. Atomicity and durability sit on opposite sides of commit
Move the crash point to just after T1 writes A = 8,500 but before it writes B = 5,500. The database must not remain at A = 8,500 and B = 4,000, a total of only 12,500. Atomicity requires rollback to the original A = 10,000 and B = 4,000.
Now move the crash to just after the database acknowledges the commit. Durability requires recovery to preserve A = 8,500 and B = 5,500. Recovery may undo incomplete work before a durable commit and redo or preserve completed work after it. Write-ahead logging is a common implementation technique, not the definition of either property.
Recognition rule: crash before completion plus partial effects points to atomicity; crash after acknowledged commit plus missing effects points to durability.
5. Consistency is about rules; isolation is about overlap
T1 has two rules to preserve: A >= 0 and A + B = 14,000. Suppose it tries to transfer 11,000 units. The debit becomes 10,000 - 11,000 = -1,000. If the non-negative balance constraint is declared, the transaction must be rejected. A badly designed transaction can be atomic yet violate a business rule. Atomicity alone does not create consistency.
Isolation deals with a different danger. Let a read-only transaction T2 run after T1 writes A = 8,500 but before T1 writes B = 5,500. If T2 combines the new A with the old B, it calculates 8,500 + 4,000 = 12,500, an impossible total for this transfer.
The isolation goal is to give T2 a view permitted by the database's isolation guarantee, such as the before state 10,000 + 4,000 = 14,000 or the after state 8,500 + 5,500 = 14,000, not that mixed intermediate state.

6. How exam and interview questions disguise the property
Do not wait for the property name. Classify the clue:
An incomplete debit or credit followed by rollback asks about atomicity.
A key, balance, or total rule asks about consistency.
A dirty read, mixed view, or overwritten in-progress value asks about isolation.
Committed data surviving a power failure asks about durability.
Acronym distractors may replace a property with deadlock-freedom or integrity. Neither is a fifth ACID property.
Use a three-step routine. First, locate the event boundary. Second, decide whether a crash or another transaction is involved. Third, ask whether the guarantee concerns completeness, validity, concurrency, or persistence. In T1 and T2, reading 8,500 and 4,000 during overlap produces 12,500. The clue is concurrency, so the answer is isolation.
Use the earlier ACID Properties in DBMS MCQs for short PYQ classification and answer explanations. The T1/T2 trace follows rollback before commit, persistence after commit, and a mixed snapshot. In interviews, explain why each property fits its clue instead of merely reciting the acronym.
7. Common traps and the correction for each
Trap: Consistency means every concurrent reader sees the same value. Correction: consistency concerns valid states and constraints; concurrent visibility belongs to isolation.
Trap: Durability means the whole transaction happens. Correction: all-or-nothing is atomicity; durability begins after commit.
Trap: ACID prevents deadlocks. Correction: deadlock handling belongs to concurrency control and is not the D in ACID.
Trap: Individually valid SQL statements make the transaction safe. Correction: test the complete unit, its before and after invariants, and any intermediate exposure.
When you are ready to study schedules, serializability, and locking, continue with Transactions and Concurrency Control in DBMS.
8. The short version and what to study next
For T1, remember four lines:
Atomicity: both balance writes happen, or neither does.
Consistency: the total stays 14,000 and declared constraints hold.
Isolation: T2 never receives the mixed 12,500 view as a valid result.
Durability: A = 8,500 and B = 5,500 survive after commit.
Redraw both timelines from memory, then classify four prompts by failure clue without looking at the property names.
For a GATE-oriented sequence, continue through Transaction Management in GATE Guidance by Sanchit Sir. Build the distinction first, then use questions to make recognition automatic.
Keep learning
ACID Properties in DBMS MCQs: 12 Solved Questions with Explanations
Solve 12 previous-year database transaction questions from GATE, IBPS, DSSSB and UGC NET papers by learning which clue points to atomicity, consistency, isolation, or durability.
Transaction Management in DBMS: ACID, Serializability, Locking and Recovery
Learn to trace DBMS transactions from operation sequences to precedence graphs, recovery rules, lock protocols, timestamp checks, and crash handling.
DBMS Transaction MCQs: 12 solved questions on ACID, serializability and locking
DBMS transaction MCQs with full solutions: 12 solved GATE and ISRO questions on ACID properties, conflict serializability, recoverability and 2PL locking.
Transactions and concurrency control in DBMS: ACID, schedules, serializability
Transactions in DBMS explained: ACID properties, schedules, conflict serializability with a worked precedence graph, two-phase locking, and the exam angle.





