pg.ddx.io  pgsql-bugs@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Andres Freund <andres@anarazel.de>
To: Stanislav Grozev <tacho@daemonz.org>
To: Peter Geoghegan <pg@heroku.com>
Cc: pgsql-bugs@postgresql.org
Subject: Re: Incorrect UPDATE trigger invocation in the UPDATE clause of an UPSERT statement.
Date: Thu, 10 Dec 2015 16:51:36 +0100
Message-ID: <20151210155136.GC2551@alap3.anarazel.de> (raw)
In-Reply-To: <CAA78GVqy1+LisN-8DygekD_Ldfy=BJLarSpjGhytOsgkpMavfQ@mail.gmail.com>
References: <CAA78GVqy1+LisN-8DygekD_Ldfy=BJLarSpjGhytOsgkpMavfQ@mail.gmail.com>
List-Unsubscribe: <mailto:majordomo@postgresql.org?body=unsub%20pgsql-bugs>

Hi,

On 2015-11-30 11:43:12 +0000, Stanislav Grozev wrote:
> I'd like to report a bug in the UPDATE trigger invocation when using the
> new INSERT ON CONFLICT UPDATE (UPSERT) functionality.
> 
> In short, if an UPDATE trigger is invoked by the ON CONFLICT DO UPDATE
> clause of an UPSERT statement - it receives the new values in both the OLD
> and NEW variables.  Whereas if invoked by a normal UPDATE statement - it
> correctly gets the respective values in OLD and NEW.

I've pushed a fix for this. Thanks for the report!

- Andres


-- 
Sent via pgsql-bugs mailing list (pgsql-bugs@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-bugs



view thread (24+ messages)

Message-ID: <20151210155136.GC2551@alap3.anarazel.de>
Permalink:  ../20151210155136.GC2551@alap3.anarazel.de/
Also on:    postgresql.org/message-id/20151210155136.GC2551@alap3.anarazel.de

 · 

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: andres@anarazel.de, tacho@daemonz.org, pg@heroku.com
  Subject: Re: Incorrect UPDATE trigger invocation in the UPDATE clause of an UPSERT statement.
  In-Reply-To: <20151210155136.GC2551@alap3.anarazel.de>
  References: <CAA78GVqy1+LisN-8DygekD_Ldfy=BJLarSpjGhytOsgkpMavfQ@mail.gmail.com> <20151210155136.GC2551@alap3.anarazel.de>

* 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