Join in PostgreSQL
Join implementations are under: src/backend/executor
PostgreSQL suports three kinds of join:
- nested loop join (
nodeNestloop.c )
- sort-merge join (
nodeMergejoin.c )
- hash join (
nodeHashjoin.c ) (hybrid hash join)
Query optimiser chooses appropriate join, by considering
- physical characteristics of tables being joined
- estimated selectivity (likely number of result tuples)
|