pg.ddx.io  pgsql-bugs@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Andres Freund <andres@anarazel.de>
To: Peter Geoghegan <pg@heroku.com>
Cc: Michael Paquier <michael.paquier@gmail.com>
Cc: Dean Rasheed <dean.a.rasheed@gmail.com>
Cc: Stanislav Grozev <tacho@daemonz.org>
Cc: PostgreSQL mailing lists <pgsql-bugs@postgresql.org>
Cc: Robert Haas <robertmhaas@gmail.com>
Subject: Re: Incorrect UPDATE trigger invocation in the UPDATE clause of an UPSERT statement.
Date: Wed, 9 Dec 2015 22:43:22 +0100
Message-ID: <20151209214322.GA14789@awork2.anarazel.de> (raw)
In-Reply-To: <CAM3SWZQJcdx0y4UBPYPvf-mfs_SMVBi3zKA2JenGeUtcQDd=cg@mail.gmail.com>
References: <CAA78GVqy1+LisN-8DygekD_Ldfy=BJLarSpjGhytOsgkpMavfQ@mail.gmail.com>
	<CAB7nPqTjO4decSSm2DxeUrchX10SJ3GfKTddgBH42bvX5k4WjQ@mail.gmail.com>
	<CAEZATCXxhKui4hCMXGyeWUeo-pTS7r4BwfzjkM7v0sOvLiAETA@mail.gmail.com>
	<CAB7nPqRioCgcGydOV5h1raa21QvYR3EiJVKY7UVdwHx=-KhcUw@mail.gmail.com>
	<CAM3SWZR4WOxAbq4=0zy4EPfRw7COufJ8tUqqP1LTypef7kAQPA@mail.gmail.com>
	<CAM3SWZSiX3_6H149ZH6QF8Y9LuaYgpg1218bbF9_cjvyykaK4w@mail.gmail.com>
	<20151208144440.GU4934@alap3.anarazel.de>
	<CAM3SWZSEF00OaCxFQErv_rOVLBtsM9n=xoxknLxs7YxMjSxYuQ@mail.gmail.com>
	<20151208231220.GG28762@awork2.anarazel.de>
	<CAM3SWZQJcdx0y4UBPYPvf-mfs_SMVBi3zKA2JenGeUtcQDd=cg@mail.gmail.com>
List-Unsubscribe: <mailto:majordomo@postgresql.org?body=unsub%20pgsql-bugs>

On 2015-12-08 15:32:03 -0800, Peter Geoghegan wrote:
> I actually think that there is an argument to be made for doing
> nothing here, and not allowing a cardinality violation at all.

Works for me. I'll add a short comment before the ExecUpdate() detailing
that the row could, in rather uncommon cases, be updated by that
point. Adding an extra parameter to ExecUpdate() + additional concerns
to it's already nontrivial HTSV codepath doesn't seem worth it to
me.

Greetings,

Andres Freund


-- 
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)  latest in thread

Message-ID: <20151209214322.GA14789@awork2.anarazel.de>
Permalink:  ../20151209214322.GA14789@awork2.anarazel.de/
Also on:    postgresql.org/message-id/20151209214322.GA14789@awork2.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, pg@heroku.com, michael.paquier@gmail.com, dean.a.rasheed@gmail.com, tacho@daemonz.org, robertmhaas@gmail.com
  Subject: Re: Incorrect UPDATE trigger invocation in the UPDATE clause of an UPSERT statement.
  In-Reply-To: <20151209214322.GA14789@awork2.anarazel.de>
  References: <CAA78GVqy1+LisN-8DygekD_Ldfy=BJLarSpjGhytOsgkpMavfQ@mail.gmail.com> <CAB7nPqTjO4decSSm2DxeUrchX10SJ3GfKTddgBH42bvX5k4WjQ@mail.gmail.com> <CAEZATCXxhKui4hCMXGyeWUeo-pTS7r4BwfzjkM7v0sOvLiAETA@mail.gmail.com> <CAB7nPqRioCgcGydOV5h1raa21QvYR3EiJVKY7UVdwHx=-KhcUw@mail.gmail.com> <CAM3SWZR4WOxAbq4=0zy4EPfRw7COufJ8tUqqP1LTypef7kAQPA@mail.gmail.com> <CAM3SWZSiX3_6H149ZH6QF8Y9LuaYgpg1218bbF9_cjvyykaK4w@mail.gmail.com> <20151208144440.GU4934@alap3.anarazel.de> <CAM3SWZSEF00OaCxFQErv_rOVLBtsM9n=xoxknLxs7YxMjSxYuQ@mail.gmail.com> <20151208231220.GG28762@awork2.anarazel.de> <CAM3SWZQJcdx0y4UBPYPvf-mfs_SMVBi3zKA2JenGeUtcQDd=cg@mail.gmail.com> <20151209214322.GA14789@awork2.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