Johnder Perez

Step 4 of 7

Indexes and ACID transactions


An index is like a book's index: it lets the database jump to rows instead of scanning the whole table. A transaction groups several changes so they all succeed or all fail (ACID: atomic, consistent, isolated, durable).

Why it matters when you build with AI: Missing indexes are why queries get slow as you grow. Missing transactions are why a payment gets recorded but the order doesn't.

Quick check

Payment recorded but order missing after a crash. What was missing?

← Previous step Next: Caching and queues →