1. Schema
A small library DB. Four tables, foreign keys drawn as arrows.
2. JOIN types — Venn
Pick a JOIN. The shaded region shows which rows make it into the result. The example query runs against the library DB below.
—
3. Index lookup vs sequential scan
Same query, two storage paths. A B-tree index turns O(n) into O(log n).
seq-scan steps—
index steps—
4. Query
A real SQLite engine running in WebAssembly. Edit, press ⌘/Ctrl-Enter, or click run.
5. Examples
Click any chip to load the query above and run it.