diff options
author | Tom Lane <tgl@sss.pgh.pa.us> | 2003-01-24 03:58:44 +0000 |
---|---|---|
committer | Tom Lane <tgl@sss.pgh.pa.us> | 2003-01-24 03:58:44 +0000 |
commit | f5e83662d06a40f90ceb3516fc88674eb6c1e4f9 (patch) | |
tree | 5b682c9bcbc9dd88b7bcc19f1ca1bf43c8335a83 /src/backend/utils/adt/selfuncs.c | |
parent | ef7422510e93266e5aa9bb926d6747d5f2ae21f4 (diff) | |
download | postgresql-f5e83662d06a40f90ceb3516fc88674eb6c1e4f9.tar.gz postgresql-f5e83662d06a40f90ceb3516fc88674eb6c1e4f9.zip |
Modify planner's implied-equality-deduction code so that when a set
of known-equal expressions includes any constant expressions (including
Params from outer queries), we actively suppress any 'var = var'
clauses that are or could be deduced from the set, generating only the
deducible 'var = const' clauses instead. The idea here is to push down
the restrictions implied by the equality set to base relations whenever
possible. Once we have applied the 'var = const' clauses, the 'var = var'
clauses are redundant, and should be suppressed both to save work at
execution and to avoid double-counting restrictivity.
Diffstat (limited to 'src/backend/utils/adt/selfuncs.c')
-rw-r--r-- | src/backend/utils/adt/selfuncs.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/backend/utils/adt/selfuncs.c b/src/backend/utils/adt/selfuncs.c index 20d353a0a50..62e0b8b32a9 100644 --- a/src/backend/utils/adt/selfuncs.c +++ b/src/backend/utils/adt/selfuncs.c @@ -15,7 +15,7 @@ * * * IDENTIFICATION - * $Header: /cvsroot/pgsql/src/backend/utils/adt/selfuncs.c,v 1.128 2003/01/22 20:16:42 tgl Exp $ + * $Header: /cvsroot/pgsql/src/backend/utils/adt/selfuncs.c,v 1.129 2003/01/24 03:58:43 tgl Exp $ * *------------------------------------------------------------------------- */ @@ -84,8 +84,8 @@ #include "optimizer/clauses.h" #include "optimizer/cost.h" #include "optimizer/pathnode.h" +#include "optimizer/paths.h" #include "optimizer/plancat.h" -#include "optimizer/planmain.h" #include "optimizer/prep.h" #include "optimizer/tlist.h" #include "optimizer/var.h" |