Explain like I'm five · Database

What is Transactions & ACID?

Transactions and ACID, told as a story about the four promises a receipt must keep.

box taken ✓, ledger write ✗the power cut out — only half of the receipt's work got donethe box is gone but the ledger still shows it

The power cut out — only half of the receipt's work got done.The box is gone but the ledger still shows it.

a half-done receiptthe ledger and the real boxes disagree, so the next person can't trust it

A half-done job leaves a ledger nobody can trust.The ledger and the real boxes disagree, so the next person can't trust it.

ACID = the four promises every receipt must keeponly a receipt keeping all four can truly be trusted

ACID is the four promises every receipt must keep.Only a receipt keeping all four can truly be trusted.

Atomicityevery step of the receipt happens, or none does
Consistencynever breaks the ledger's rules
Isolationdoesn't bleed into others' work
Durabilityonce stamped, it stays
the four letters A-C-I-Datomicity — all or nothingno half-done workconsistency — never breaks the rulesrolls back on violationisolation — doesn't leak into others' worktuned by isolation leveldurability — once stamped, it stayssurvives even a power cut

Each of ACID's four letters stands for one promise.Isolation is fine-tuned via isolation levels.

fully keeping ACID means you can trust the ledgerbut it can run slower than the express desk (in-memory DB)ledger safety and processing speed often trade off

Fully keeping ACID makes the ledger trustworthy, but receipt processing can slow down.Ledger safety and processing speed often trade off.

In one breath

ACID is the four promises a receipt (transaction) must keep: atomicity, consistency, isolation, durability.

A transaction is an indivisible unit of work in a database, and ACID is the set of four properties that make it safe: Atomicity (all succeed or all fail), Consistency (constraints are preserved), Isolation (concurrent transactions don't interfere), and Durability (committed results persist permanently). Isolation's strength is tuned via isolation levels.

When grown-ups say it

Transaction
One receipt's unit of work. The smallest unit that can't be split further.
Atomicity
All or nothing. No stopping halfway.
Consistency
Never breaking the ledger's rules. Always honors the constraints.
Isolation
Not bleeding into someone else's work. Fine-tuned by isolation level. → how much to hide when hands overlap
Durability
Once stamped, it never disappears. Stamped records survive even a power outage.
Concurrency Control
The method that stops simultaneous edits colliding. How isolation is actually implemented. → the no-collision rule
In-Memory DB
A desk that skips the deep shelf and serves from memory. Sometimes trades off durability for speed. → the express pickup desk
NoSQL Modeling
A warehouse reshaping shelves to fit the box. Many products don't keep ACID as strictly as the relational warehouse. → the free-shelf warehouse
Next story
The Rule That Keeps Simultaneous Hands From Colliding →
Want another term as a picture book? Request →