From: | tgl(at)postgresql(dot)org (Tom Lane) |
---|---|
To: | pgsql-committers(at)postgresql(dot)org |
Subject: | pgsql: Fix cost estimates for EXISTS subqueries that are evaluated as |
Date: | 2007-09-22 21:36:40 |
Message-ID: | 20070922213640.56A1C753E4C@cvs.postgresql.org |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-committers |
Log Message:
-----------
Fix cost estimates for EXISTS subqueries that are evaluated as initPlans
(because they are uncorrelated with the immediate parent query). We were
charging the full run cost to the parent node, disregarding the fact that
only one row need be fetched for EXISTS. While this would only be a
cosmetic issue in most cases, it might possibly affect planning outcomes
if the parent query were itself a subquery to some upper query.
Per recent discussion with Steve Crawford.
Modified Files:
--------------
pgsql/src/backend/optimizer/path:
costsize.c (r1.185 -> r1.186)
(http://developer.postgresql.org/cvsweb.cgi/pgsql/src/backend/optimizer/path/costsize.c?r1=1.185&r2=1.186)
pgsql/src/backend/optimizer/plan:
subselect.c (r1.124 -> r1.125)
(http://developer.postgresql.org/cvsweb.cgi/pgsql/src/backend/optimizer/plan/subselect.c?r1=1.124&r2=1.125)
pgsql/src/include/optimizer:
cost.h (r1.88 -> r1.89)
(http://developer.postgresql.org/cvsweb.cgi/pgsql/src/include/optimizer/cost.h?r1=1.88&r2=1.89)
From | Date | Subject | |
---|---|---|---|
Next Message | Tom Lane | 2007-09-23 15:58:58 | pgsql: Temporarily modify tsearch regression tests to suppress notice |
Previous Message | Andrew Dunstan | 2007-09-22 20:38:10 | pgsql: Replace calls to external dir program with perlish globs and |