Choosing the right database

Stage 1 · Lesson 4 of 6

How correct must the data be, and how fast

Start from the data, not the product

Some data must never be wrong, even for a moment: a wallet balance, seats left on a bus, stock in a shop. For these you want , where a group of changes either all happen or none do, and two people cannot both buy the last seat.

Other data can be slightly stale without harm: a like counter, a "people also viewed" list, a dashboard refreshed every minute. That data can live in a cache or a store with , where copies catch up after a short delay. Mark each piece of your data as "must be exact" or "can be a little behind".

The answer often decides between a , which gives strong guarantees by default, and faster tools that relax them.

Common trapputting money or inventory in a store chosen only for speed.

A question to check yourself, an AI practice session and 2 cheat sheet entries come with the full roadmap. Unlock

Resources for this stage

Start with· follow one of these

Practise

  • Pick any dataset and practise describing its shape, size and the questions you would ask of it

Keep handy

  • The data types chapter shows how much one relational database can store, JSON included

  • The data modelling introduction shows the same questions from the document side

Also worth your time

Mark this stage as not done?