postgresql-bitmap-heap-scan · shipping · also PostgreSQL bitmap heap scan

Bitmap heap scan (PostgreSQL)

A PostgreSQL bitmap heap scan retrieves visible table tuples selected by a bitmap and performs any required predicate rechecks.

Related Observatory article: Read on hesela.com

Selection: Exact bitmap entries retain tuple offsets, while lossy entries retain candidate pages. Heap access applies snapshot visibility; an index location is not itself a visible result row. [2] [5]

Rechecks: Exact locations do not guarantee exact predicate matches. An exact page has a separate recheck flag; intersecting exact offsets with a lossy page can retain the offsets but require predicate verification. Increasing work_mem does not eliminate an index access method's approximate matches. [2] [1]

Reading EXPLAIN: Recheck Cond displays a planned condition, not a count of evaluations. Rows Removed by Index Recheck counts failed rechecks, not every rechecked tuple; Rows Removed by Filter describes a separate filter. Zero recheck removals does not prove no recheck ran. [3] [4]

Units: Removal counts are rounded per-loop averages; exact/lossy Heap Blocks counters are not divided by loops. Neither measures unique physical-device reads. These fields describe candidate processing, not full TOAST-value verification. [4] [6]

Relations

related
Bitmap index scan (PostgreSQL), Index-only scan (PostgreSQL), Existence bitmap

Citations

  1. PostgreSQL 18: Using EXPLAIN (accessed 2026-11-18)
  2. PostgreSQL REL_18_0: TID bitmap precision, recheck flags and intersections (accessed 2026-11-18)
  3. PostgreSQL REL_18_0: bitmap heap scan predicate rechecks (accessed 2026-11-18)
  4. PostgreSQL REL_18_0: EXPLAIN instrumentation and loop denominators (accessed 2026-11-18)
  5. PostgreSQL REL_18_0: heap bitmap visibility and tuple retrieval (accessed 2026-11-18)
  6. PostgreSQL 18: TOAST and deferred external-value retrieval (accessed 2026-11-18)
Sources & caveats
  • Counter details refer to PostgreSQL REL_18_0. Documentary comparison with the separate PostgreSQL 16.15 TOAST experiment does not extend its measured coverage.

JSON: /data/terms/postgresql-bitmap-heap-scan.json

Published by Hesela team · Updated

Report a correction · Editorial standards · Reuse guidance

Cite this page
Hesela team. Bitmap heap scan (PostgreSQL). Hesela. 2026-11-19. https://hesela.dev/terms/postgresql-bitmap-heap-scan/