]> granicus.if.org Git - postgresql/commit
Support MergeAppend plans, to allow sorted output from append relations.
authorTom Lane <tgl@sss.pgh.pa.us>
Thu, 14 Oct 2010 20:56:39 +0000 (16:56 -0400)
committerTom Lane <tgl@sss.pgh.pa.us>
Thu, 14 Oct 2010 20:57:57 +0000 (16:57 -0400)
commit11cad29c91524aac1d0b61e0ea0357398ab79bf8
treeec9053dfee621437146f29ce20904a9949b3f2ae
parent30e749dece0e6502d4dd0a3b2892eab61f8c073b
Support MergeAppend plans, to allow sorted output from append relations.

This patch eliminates the former need to sort the output of an Append scan
when an ordered scan of an inheritance tree is wanted.  This should be
particularly useful for fast-start cases such as queries with LIMIT.

Original patch by Greg Stark, with further hacking by Hans-Jurgen Schonig,
Robert Haas, and Tom Lane.
26 files changed:
src/backend/commands/explain.c
src/backend/executor/Makefile
src/backend/executor/execAmi.c
src/backend/executor/execCurrent.c
src/backend/executor/execProcnode.c
src/backend/executor/nodeMergeAppend.c [new file with mode: 0644]
src/backend/nodes/copyfuncs.c
src/backend/nodes/outfuncs.c
src/backend/optimizer/README
src/backend/optimizer/path/allpaths.c
src/backend/optimizer/path/costsize.c
src/backend/optimizer/path/equivclass.c
src/backend/optimizer/plan/createplan.c
src/backend/optimizer/plan/setrefs.c
src/backend/optimizer/plan/subselect.c
src/backend/optimizer/util/pathnode.c
src/backend/utils/adt/ruleutils.c
src/include/executor/nodeMergeAppend.h [new file with mode: 0644]
src/include/nodes/execnodes.h
src/include/nodes/nodes.h
src/include/nodes/plannodes.h
src/include/nodes/relation.h
src/include/optimizer/cost.h
src/include/optimizer/pathnode.h
src/test/regress/expected/inherit.out
src/test/regress/sql/inherit.sql