Create the planner mechanism for optimizing simple MIN and MAX queries
authorTom Lane <tgl@sss.pgh.pa.us>
Mon, 11 Apr 2005 23:06:57 +0000 (23:06 +0000)
committerTom Lane <tgl@sss.pgh.pa.us>
Mon, 11 Apr 2005 23:06:57 +0000 (23:06 +0000)
commit52de7f68778c04ec538375734dd29f5175d7b5cb
tree6258cc7c99930a518c394f29e686083ec30325b8
parent35cc869f30695eccb36b8fe8653107cf8f3e4034
Create the planner mechanism for optimizing simple MIN and MAX queries
into indexscans on matching indexes.  For the moment, it only handles
int4 and text datatypes; next step is to add a column to pg_aggregate
so that all MIN/MAX aggregates can be handled.  Per my recent proposal.
14 files changed:
src/backend/optimizer/path/indxpath.c
src/backend/optimizer/plan/Makefile
src/backend/optimizer/plan/planagg.c [new file with mode: 0644]
src/backend/optimizer/plan/planner.c
src/backend/optimizer/plan/subselect.c
src/backend/utils/cache/lsyscache.c
src/include/optimizer/paths.h
src/include/optimizer/planmain.h
src/include/optimizer/subselect.h
src/include/utils/lsyscache.h
src/test/regress/expected/aggregates.out
src/test/regress/expected/create_index.out
src/test/regress/sql/aggregates.sql
src/test/regress/sql/create_index.sql