enable_partitionwise_join
No restart — settable per sessiontuned by pgconfiguratorboolean (on/off)
Lets the planner join matching partitions pair-by-pair instead of as whole tables.
What pgconfigurator would set
32 GB · 8 vCPU · NVMe · OLTP
Computing…
Tune for your exact server → /tunecomputed in your browser · nothing uploaded
What it does
When two partitioned tables are joined on their partition key, this lets the planner join each matching pair of partitions separately and combine the results. That produces smaller, cheaper per-partition joins (and parallelizes better) than joining the fully-combined tables.
How to tune it
It's off by default because planning these joins costs more time and memory. Turn it on for analytical workloads that join large, identically-partitioned tables on the partition key — the execution win usually dwarfs the extra planning. Less useful for OLTP or non-aligned partitioning.
Related plan nodes
FAQ
- Why is partitionwise join off by default?
- It increases planning time and memory, which isn't worth it for the many queries that don't join aligned partitioned tables. Enable it (often per session) for the analytical queries that do.