Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1tGjbY-000OB0-9n for pgsql-general@arkaria.postgresql.org; Thu, 28 Nov 2024 18:51:08 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.94.2) (envelope-from ) id 1tGjbV-000eKb-OT for pgsql-general@arkaria.postgresql.org; Thu, 28 Nov 2024 18:51:06 +0000 Received: from makus.postgresql.org ([2001:4800:3e1:1::229]) by malur.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1tGjbV-000eKS-DF for pgsql-general@lists.postgresql.org; Thu, 28 Nov 2024 18:51:06 +0000 Received: from sss.pgh.pa.us ([68.162.161.243]) by makus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1tGjbU-0002Wu-02 for pgsql-general@postgresql.org; Thu, 28 Nov 2024 18:51:05 +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 4ASIp2X6023001; Thu, 28 Nov 2024 13:51:02 -0500 From: Tom Lane To: Bertrand Mamasam cc: pgsql-general@postgresql.org Subject: Re: ERROR wrong varnullingrels (b 3) (expected (b)) with LEFT JOIN LATERAL and CTE In-reply-to: References: <2090950.1732810550@sss.pgh.pa.us> Comments: In-reply-to Bertrand Mamasam message dated "Thu, 28 Nov 2024 18:29:01 +0100" MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-ID: <22999.1732819862.1@sss.pgh.pa.us> Date: Thu, 28 Nov 2024 13:51:02 -0500 Message-ID: <23000.1732819862@sss.pgh.pa.us> List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk Bertrand Mamasam writes: > Ok thank you, here is a short version of the query that works before 16.5 > but not in 16.5+ anymore. Thanks for the test case! A quick "git bisect" says I broke it at cb8e50a4a09fe541e32cd54ea90a97f2924121a1 is the first bad commit commit cb8e50a4a09fe541e32cd54ea90a97f2924121a1 Author: Tom Lane Date: Fri Aug 30 12:42:12 2024 -0400 Avoid inserting PlaceHolderVars in cases where pre-v16 PG did not. Apparently that change was less safe than I thought. Looking ... regards, tom lane