brin · shipping · also BRIN, BRIN index, PostgreSQL BRIN, Block Range Index

Block Range Index (BRIN)

A PostgreSQL BRIN index summarizes groups of adjacent heap pages so queries can exclude page ranges that cannot satisfy their conditions.

Candidates: The executor rechecks rows in candidate ranges; a candidate need not match. BRIN is not just min-max: PostgreSQL 18 also has minmax-multi, inclusion and Bloom classes. [1]

Granularity: pages_per_range counts heap pages, not rows or Parquet pages; PostgreSQL 18 defaults to 128. Finer ranges cost more summaries but may prune better. [2]

Coverage: An unsummarized range remains a scan candidate, not an empty range. This is not protection against corrupt index metadata. [3]

Maintenance: autosummarize defaults to off. brin_summarize_new_values() covers missing summaries. brin_summarize_range() covers a range only if it is unsummarized; it does not refresh an existing summary. Desummarizing then summarizing can tighten bounds after deletions, not verify integrity. [4]

Native check: In PostgreSQL 16.15, DELETE and VACUUM left broad bounds; rebuilding avoided one heap block and 100 rejections without changing answers. Three fresh-cluster repeats covered 42 stage/query observations on a one-page fixture with forced plans; not speed or physical-I/O measurements, nor PostgreSQL 18 execution. [6]

Inspection: Follow the range-map pointer. After desummarization, the raw page scan still exposed an old tuple although its range-map entry was invalid; it was not an active summary. [6] [7]

Relations

related
Zone map (min-max index), Bloom filter

Citations

  1. PostgreSQL 18: BRIN indexes and operator classes (accessed 2026-11-18)
  2. PostgreSQL 18: CREATE INDEX, BRIN storage parameters (accessed 2026-11-18)
  3. PostgreSQL REL_18_0: BRIN scan and unsummarized-range design (accessed 2026-11-18)
  4. PostgreSQL 18: index maintenance functions (accessed 2026-11-18)
  5. Hesela: native PostgreSQL 16.15 BRIN maintenance, replay and observations (accessed 2026-11-18)
  6. PostgreSQL REL_16_15: range-map lookup and desummarization (accessed 2026-11-18)

Further reading

  1. Hesela: candidate pruning is not integrity verification (accessed 2026-11-18)
Sources & caveats
  • PostgreSQL 18 documentation synthesis, plus a separate native PostgreSQL 16.15 controlled experiment recorded 2026-11-18; no PostgreSQL 18 execution or performance measurement.
  • Author-verified synthetic fixtures, exact sequential-result controls and three fresh-cluster repetitions; no independent scientific replication.

JSON: /data/terms/brin.json

Published by Hesela team · Updated

Report a correction · Editorial standards · Reuse guidance

Cite this page
Hesela team. Block Range Index (BRIN). Hesela. 2026-11-18. https://hesela.dev/terms/brin/