]> granicus.if.org Git - postgresql/commit
Adjust subquery qual pushdown rules to be more forgiving: if a qual
authorTom Lane <tgl@sss.pgh.pa.us>
Sat, 22 Mar 2003 01:49:38 +0000 (01:49 +0000)
committerTom Lane <tgl@sss.pgh.pa.us>
Sat, 22 Mar 2003 01:49:38 +0000 (01:49 +0000)
commit05f916e6add9726bf4ee046e4060c1b03c9961f2
treed5045cb6bd1b27d4b9af7c05c94e53e6c08736b9
parente43094b1249a0e2814d0759d545ccfe786baef3d
Adjust subquery qual pushdown rules to be more forgiving: if a qual
refers to a non-DISTINCT output column of a DISTINCT ON subquery, or
if it refers to a function-returning-set, we cannot push it down.
But the old implementation refused to push down *any* quals if the
subquery had any such 'dangerous' outputs.  Now we just look at the
output columns actually referenced by each qual expression.  More code
than before, but probably no slower since we don't make unnecessary checks.
src/backend/optimizer/path/allpaths.c
src/backend/optimizer/util/clauses.c
src/backend/parser/parse_clause.c
src/include/parser/parse_clause.h