pg.ddx.io  pgsql-bugs@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Michael Paquier <michael@paquier.xyz>
To: Zsolt Parragi <zsolt.parragi@percona.com>
Cc: Ayush Tiwari <ayushtiwari.slg01@gmail.com>
Cc: hackerzheng666@gmail.com
Cc: pgsql-bugs@lists.postgresql.org
Subject: Re: BUG #19632: RULE rewriting crashes with XX000 when RETURNING old/new references a system column
Date: Fri, 21 Aug 2026 07:53:14 +0900
Message-ID: <aoeFWookuVmnletx@paquier.xyz> (raw)
In-Reply-To: <CAN4CZFNJrt--xPEuQgFxg3TtNFPAifc9SbQbP=K_8fUUYDnh9Q@mail.gmail.com>
References: <19632-9155d9baec763c8c@postgresql.org>
	<CAN4CZFOTLqGioJfRrQhCq0c2j0fcoG7FA4vMOOwc_Bg1fXheVQ@mail.gmail.com>
	<aoY-IVnSckypD-O-@paquier.xyz>
	<CAN4CZFNJrt--xPEuQgFxg3TtNFPAifc9SbQbP=K_8fUUYDnh9Q@mail.gmail.com>

On Thu, Aug 20, 2026 at 09:29:36AM +0100, Zsolt Parragi wrote:
> Right, I thought you can't implement soft delete with triggers but of
> course you can. Except that RETURNING doesn't work at all in that
> case, unless I make it a delete+insert or also introduce a helper
> view, but even with the view I can only get out the old xmin, not the
> new.

For now I have applied your patch on HEAD as of d39762b8c79a,
qualifying as a life improvement thing with a better message.  I have
never really seen somebody complain about that limitation, as well..
--
Michael

Attachments:

  [application/pgp-signature] signature.asc (832B, ../aoeFWookuVmnletx@paquier.xyz/2-signature.asc)
  download

view thread (9+ messages)  latest in thread

Message-ID: <aoeFWookuVmnletx@paquier.xyz>
Permalink:  ../aoeFWookuVmnletx@paquier.xyz/
Also on:    postgresql.org/message-id/aoeFWookuVmnletx@paquier.xyz

 · 

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 using the --to and --cc options:
  reply via email

  To: pgsql-bugs@postgresql.org
  Cc: michael@paquier.xyz, zsolt.parragi@percona.com, ayushtiwari.slg01@gmail.com, hackerzheng666@gmail.com, pgsql-bugs@lists.postgresql.org
  Subject: Re: BUG #19632: RULE rewriting crashes with XX000 when RETURNING old/new references a system column
  In-Reply-To: <aoeFWookuVmnletx@paquier.xyz>

* 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