Use exact nullingrels matches for NestLoopParams - Mailing list pgsql-hackers

From Richard Guo
Subject Use exact nullingrels matches for NestLoopParams
Date
Msg-id CAMbWs482_DFHzQ079ZPp6c8UvmFdz3Jj+4K8tVRu9g2Bw34NPA@mail.gmail.com
Whole thread Raw
List pgsql-hackers
As noted in the commit message of 66e9df9f6, we can now safely use
NRM_EQUAL to process NestLoopParams in setrefs.c.  This is because
identify_current_nestloop_params now ensures that Vars or PHVs seen in
a NestLoopParam expression have nullingrels that include exactly the
outer-join relids that appear in the outer side's output and can null
the respective Var or PHV.

Here is a patch that makes that change.  It also removes the
NRM_SUBSET enum value, along with all remaining checks for it, since
it is no longer used.

(I'm wondering if we have a way to identify the nullingrels added by
an outer join when fixing up its targetlist and qpqual.  If so, we
might be able to switch to exact nullingrels matches for them and
thereby get rid of NRM_SUPERSET too.)

- Richard

Attachment

pgsql-hackers by date:

Previous
From: Chao Li
Date:
Subject: Re: [PATCH} Move instrumentation structs
Next
From: Peter Eisentraut
Date:
Subject: Re: Reorganize GUC structs