pg.ddx.io  pgsql-bugs@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Tom Lane <tgl@sss.pgh.pa.us>
To: Alvaro Herrera <alvherre@alvh.no-ip.org>
Cc: Richard Guo <guofenglinux@gmail.com>
Cc: borz_off@cs.msu.su, PostgreSQL mailing lists <pgsql-bugs@lists.postgresql.org>
Subject: Re: BUG #17579: 15beta2: strange error when trying to use MERGE statement as a CTE
Date: Thu, 11 Aug 2022 10:23:15 -0400
Message-ID: <485520.1660227795@sss.pgh.pa.us> (raw)
In-Reply-To: <20220811141745.pdor4vr2ktuauygk@alvherre.pgsql>
References: <20220811141745.pdor4vr2ktuauygk@alvherre.pgsql>

Alvaro Herrera <alvherre@alvh.no-ip.org> writes:
> On 2022-Aug-11, Tom Lane wrote:
>> The parse error location seems quite oddly chosen.  Can you make
>> it point at the MERGE instead?  I think exprLocation(cte->ctequery)
>> might work, but not sure.

> I tried, but couldn't find the location anywhere.  None of the nodes for
> ModifyTable statements have location :-(

Ah, right, in particular MergeStmt doesn't.

> We could add one now -- while
> it's a bit late for 15, we're likely going to have a catversion bump due
> to the JSON revert, so it might be fine.

Nah, not worth it just for this.

			regards, tom lane





view thread (10+ messages)  latest in thread

Message-ID: <485520.1660227795@sss.pgh.pa.us>
Permalink:  ../485520.1660227795@sss.pgh.pa.us/
Also on:    postgresql.org/message-id/485520.1660227795@sss.pgh.pa.us

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-bugs@postgresql.org
  Cc: tgl@sss.pgh.pa.us, alvherre@alvh.no-ip.org, guofenglinux@gmail.com
  Subject: Re: BUG #17579: 15beta2: strange error when trying to use MERGE statement as a CTE
  In-Reply-To: <485520.1660227795@sss.pgh.pa.us>
  References: <20220811141745.pdor4vr2ktuauygk@alvherre.pgsql> <485520.1660227795@sss.pgh.pa.us>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox