diff options
| author | Tom Lane <tgl@sss.pgh.pa.us> | 2010-01-01 23:03:10 +0000 |
|---|---|---|
| committer | Tom Lane <tgl@sss.pgh.pa.us> | 2010-01-01 23:03:10 +0000 |
| commit | 7839d35991f1c79a291e67635d5f4c5750c16e9b (patch) | |
| tree | 98f44976c68f2ac0b707f4efcc8f3949cdc9ac68 /src/backend/optimizer/path | |
| parent | 29c4ad98293e3c5cb3fcdd413a3f4904efff8762 (diff) | |
| download | postgresql-7839d35991f1c79a291e67635d5f4c5750c16e9b.tar.gz | |
Add an "argisrow" field to NullTest nodes, following a plan made way back in
8.2beta but never carried out. This avoids repetitive tests of whether the
argument is of scalar or composite type. Also, be a bit more paranoid about
composite arguments in some places where we previously weren't checking.
Diffstat (limited to 'src/backend/optimizer/path')
| -rw-r--r-- | src/backend/optimizer/path/indxpath.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/backend/optimizer/path/indxpath.c b/src/backend/optimizer/path/indxpath.c index 456a5b9be4..c69dd8686d 100644 --- a/src/backend/optimizer/path/indxpath.c +++ b/src/backend/optimizer/path/indxpath.c @@ -9,7 +9,7 @@ * * * IDENTIFICATION - * $PostgreSQL: pgsql/src/backend/optimizer/path/indxpath.c,v 1.243 2010/01/01 21:53:49 tgl Exp $ + * $PostgreSQL: pgsql/src/backend/optimizer/path/indxpath.c,v 1.244 2010/01/01 23:03:10 tgl Exp $ * *------------------------------------------------------------------------- */ @@ -1256,7 +1256,8 @@ match_clause_to_indexcol(IndexOptInfo *index, { NullTest *nt = (NullTest *) clause; - if (match_index_to_operand((Node *) nt->arg, indexcol, index)) + if (!nt->argisrow && + match_index_to_operand((Node *) nt->arg, indexcol, index)) return true; return false; } |
