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.96) (envelope-from ) id 1x1RF2-005C51-2q for pgsql-bugs@arkaria.postgresql.org; Tue, 01 Sep 2026 16:21:44 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.96) (envelope-from ) id 1x1RF1-007AyH-1n for pgsql-bugs@arkaria.postgresql.org; Tue, 01 Sep 2026 16:21:43 +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.96) (envelope-from ) id 1x1RF1-007Ay8-0z for pgsql-bugs@lists.postgresql.org; Tue, 01 Sep 2026 16:21:43 +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.98.2) (envelope-from ) id 1x1REz-00000003UhK-335k for pgsql-bugs@lists.postgresql.org; Tue, 01 Sep 2026 16:21:42 +0000 Received: from sss1.sss.pgh.pa.us (localhost [127.0.0.1]) by sss.pgh.pa.us (8.18.1/8.18.1) with ESMTP id 681GLRpU1260129; Tue, 1 Sep 2026 12:21:27 -0400 From: Tom Lane To: Andrey Rachitskiy cc: i.portnov@compassplus.com, pgsql-bugs@lists.postgresql.org Subject: Re: BUG #19487: Error while executing SQL query involving XML parsing In-reply-to: References: <19487-367258bc497b923a@postgresql.org> <1589702.1787946553@sss.pgh.pa.us> <255521.1788039871@sss.pgh.pa.us> <880213.1788113038@sss.pgh.pa.us> Comments: In-reply-to Andrey Rachitskiy message dated "Sun, 30 Aug 2026 23:35:13 +0500" MIME-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Content-ID: <1260127.1788279687.1@sss.pgh.pa.us> Content-Transfer-Encoding: 8bit Date: Tue, 01 Sep 2026 12:21:27 -0400 Message-ID: <1260128.1788279687@sss.pgh.pa.us> List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk Andrey Rachitskiy writes: > вс, 30 авг. 2026 г. в 23:04, Tom Lane : >> I've got mixed emotions about back-patching this. It's not really >> a bug fix, because we already disclaim the safety of relying on >> CASE for this purpose, cf [1]. I think it might still be reasonable >> to sneak into v19, but I'm unsure that putting it into 18 is a good >> idea. > On back-patching: I share the hesitation about 18. At the same time, > SQL-language functions with this pattern did work on earlier branches and > broke for some users after the plan-cache change in 18. I would be fine > with putting it into 19 and master. If we back-patch to 18, I would treat > it as a narrow regression fix rather than a semantic promise about CASE. > Either way works for me. After thinking about it for a day or so, I elected to push just as far as 19. While it's true that this fixes the reported problem, it seems possible that it de-optimizes somebody else's query. People don't like that in minor releases... regards, tom lane