What are ACID Properties in DBMS?
MediumCommonMajor: software engineeringgoogle, amazon, microsoft
Concept
ACID ensures reliable transactions in relational databases: Atomicity, Consistency, Isolation, Durability.
Key Points
| Property | What it Guarantees | Quick Example |
|---|---|---|
| Atomicity | All or nothing | Debit + credit both succeed or both roll back |
| Consistency | Constraints preserved | Foreign keys, CHECKs remain valid after commit |
| Isolation | Concurrent transactions don’t interfere logically | Reads don’t see partial/in-flight writes |
| Durability | Committed data survives crashes | WAL/redo logs ensure persistence |
Interview Tips
- Map isolation to anomalies (dirty read, non-repeatable read, phantom).
- Mention isolation levels (Read Committed, Repeatable Read, Serializable).
- Tie to WAL, 2PC, or distributed edge cases.
Reference
Source: InterviewBit DBMS & CS interview topics.