Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1puXyS-0002pw-4B for pgsql-hackers@arkaria.postgresql.org; Thu, 04 May 2023 12:22:16 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1puXyQ-0008HM-QE for pgsql-hackers@arkaria.postgresql.org; Thu, 04 May 2023 12:22:14 +0000 Received: from makus.postgresql.org ([2001:4800:3e1:1::229]) by malur.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1puXyQ-0008HB-I2 for pgsql-hackers@lists.postgresql.org; Thu, 04 May 2023 12:22:14 +0000 Received: from sss.pgh.pa.us ([66.207.139.130]) by makus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1puXyO-000Tts-5j for pgsql-hackers@lists.postgresql.org; Thu, 04 May 2023 12:22:13 +0000 Received: from sss1.sss.pgh.pa.us (localhost [127.0.0.1]) by sss.pgh.pa.us (8.15.2/8.15.2) with ESMTP id 344CM4pY3197070; Thu, 4 May 2023 08:22:04 -0400 From: Tom Lane To: "Anton A. Melnikov" cc: Justin Pryzby , Richard Guo , pgsql-hackers@lists.postgresql.org, "Finnerty, Jim" Subject: Re: Making Vars outer-join aware In-reply-to: <5b370a46-f6d2-373d-9dbc-0d55250e82c1@inbox.ru> References: <1035990.1667261942@sss.pgh.pa.us> <2901865.1667685211@sss.pgh.pa.us> <4019771.1672155080@sss.pgh.pa.us> <323812.1672241806@sss.pgh.pa.us> <2043562.1674506286@sss.pgh.pa.us> <20230212235823.GW1653@telsasoft.com> <20230213184807.GF1653@telsasoft.com> <5b370a46-f6d2-373d-9dbc-0d55250e82c1@inbox.ru> Comments: In-reply-to "Anton A. Melnikov" message dated "Thu, 04 May 2023 10:22:36 +0300" MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-ID: <3197068.1683202924.1@sss.pgh.pa.us> Content-Transfer-Encoding: quoted-printable Date: Thu, 04 May 2023 08:22:04 -0400 Message-ID: <3197069.1683202924@sss.pgh.pa.us> List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk "Anton A. Melnikov" writes: > The thing is that for custom scan nodes as readme says: > "INDEX_VAR is abused to signify references to columns of a custom scan t= uple type" > But INDEX_VAR has a negative value, so it can not be used in varnullingr= els bitmapset. > And therefore this improvement seems will not work with custom scan node= s and some > extensions that use such nodes. Under what circumstances would you be trying to inject INDEX_VAR into a nullingrel set? Only outer-join relids should ever appear there. AFAICS the change you propose would serve only to mask bugs. regards, tom lane