aboutsummaryrefslogtreecommitdiff
path: root/src/backend/executor/nodeHash.c
diff options
context:
space:
mode:
authorTom Lane <tgl@sss.pgh.pa.us>2000-01-19 23:55:03 +0000
committerTom Lane <tgl@sss.pgh.pa.us>2000-01-19 23:55:03 +0000
commit6d1efd76fb9852b8bc242dcaf35916090d7c5899 (patch)
treef827384a43f7dc18532337d555038e02498368b0 /src/backend/executor/nodeHash.c
parent08fb7375e35863e0ba2b8bb6a6c75802ca13fe85 (diff)
downloadpostgresql-6d1efd76fb9852b8bc242dcaf35916090d7c5899.tar.gz
postgresql-6d1efd76fb9852b8bc242dcaf35916090d7c5899.zip
Fix handling of NULL constraint conditions: per SQL92 spec, a NULL result
from a constraint condition does not violate the constraint (cf. discussion on pghackers 12/9/99). Implemented by adding a parameter to ExecQual, specifying whether to return TRUE or FALSE when the qual result is really NULL in three-valued boolean logic. Currently, ExecRelCheck is the only caller that asks for TRUE, but if we find any other places that have the wrong response to NULL, it'll be easy to fix them.
Diffstat (limited to 'src/backend/executor/nodeHash.c')
-rw-r--r--src/backend/executor/nodeHash.c7
1 files changed, 2 insertions, 5 deletions
diff --git a/src/backend/executor/nodeHash.c b/src/backend/executor/nodeHash.c
index 1995048e2db..46307a2aa96 100644
--- a/src/backend/executor/nodeHash.c
+++ b/src/backend/executor/nodeHash.c
@@ -6,7 +6,7 @@
* Copyright (c) 1994, Regents of the University of California
*
*
- * $Id: nodeHash.c,v 1.42 2000/01/09 00:26:18 tgl Exp $
+ * $Id: nodeHash.c,v 1.43 2000/01/19 23:54:55 tgl Exp $
*
*-------------------------------------------------------------------------
*/
@@ -584,7 +584,6 @@ ExecScanHashBucket(HashJoinState *hjstate,
{
HeapTuple heapTuple = &hashTuple->htup;
TupleTableSlot *inntuple;
- bool qualResult;
/* insert hashtable's tuple into exec slot so ExecQual sees it */
inntuple = ExecStoreTuple(heapTuple, /* tuple to store */
@@ -593,9 +592,7 @@ ExecScanHashBucket(HashJoinState *hjstate,
false); /* do not pfree this tuple */
econtext->ecxt_innertuple = inntuple;
- qualResult = ExecQual(hjclauses, econtext);
-
- if (qualResult)
+ if (ExecQual(hjclauses, econtext, false))
{
hjstate->hj_CurTuple = hashTuple;
return heapTuple;