DBMS Tutorial · Revision notes

Indexing, B+ Trees & NoSQL Systems

An index is like the index at the back of a book: it helps the database find rows quickly without reading the whole table. B+ trees are the most common index structure. NoSQL systems are databases that do not use the usual table model.

Quick revision

  • Index = fast search, slower writes, extra space
  • Dense: one entry per record. Sparse: one entry per block (sorted file)
  • One primary/clustering index per file; many secondary indexes
  • B+ tree: balanced, data in leaves, leaves linked
  • Order: p·P + (p−1)·K ≤ block size
  • SQL = fixed schema + ACID. NoSQL = flexible schema + BASE
  • CAP: pick two; P is unavoidable so choose CP or AP
Read the full Indexing, B+ Trees & NoSQL Systems notes on Doubtclip →