Parameter · Query Tuning / Planner Cost Constants
min_parallel_index_scan_size
Sets the minimum amount of index data for a parallel scan. If the planner estimates that it will read a number of index pages too small to reach this limit, a parallel scan will not be considered.
- Default:
512kB - Type: integer (8kB)
- Range: 0 … 5726623056kB
- Applies: Session (any user)
In plain words
Like its table-scan sibling, this decides when an index is big enough to be scanned by several workers. The planner looks at how much of the index the scan will actually read. Below this size, no parallel index scan.
For DBAs and operators
Only B-tree indexes support parallel index scans and parallel index-only scans (bitmap heap scans can be parallel too, but the bitmap is built by one process). The size compared is the number of index pages the scan is estimated to read, not the whole index.
The same log-3 rule as for tables applies: 1 worker at the threshold (default 512kB), +1 at 3×, 9×, 27×…, capped by max_parallel_workers_per_gather. For an index scan the planner calculates workers for both the heap pages and the index pages; if either is under its threshold (min_parallel_table_scan_size or this one), there is no parallel plan, otherwise the smaller of the two counts is used.
CREATE INDEX parallelism is separate: it is governed by max_parallel_maintenance_workers and the table's parallel_workers setting, not by this parameter.
How to change it
Any user can change it for their session with SET.
See it in context
Related parameters
min_parallel_table_scan_size max_parallel_workers_per_gather max_parallel_maintenance_workers