Re: INSERT ... ON CONFLICT UPDATE/IGNORE 4.0

From: Andres Freund <andres(at)anarazel(dot)de>
To: Peter Geoghegan <pg(at)heroku(dot)com>
Cc: hlinnaka <hlinnaka(at)iki(dot)fi>, Jeff Janes <jeff(dot)janes(at)gmail(dot)com>, Stephen Frost <sfrost(at)snowman(dot)net>, Dean Rasheed <dean(dot)a(dot)rasheed(at)gmail(dot)com>, Bruce Momjian <bruce(at)momjian(dot)us>, Pg Hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: INSERT ... ON CONFLICT UPDATE/IGNORE 4.0
Date: 2015-05-06 15:20:07
Message-ID: 20150506152007.GN9855@alap3.anarazel.de
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-admin pgsql-hackers

On 2015-05-05 15:00:56 -0700, Peter Geoghegan wrote:
> Locking the row is not "nothing", though. If you want to lock the row,
> use an UPSERT with a tautologically false WHERE clause (like "WHERE
> false").

That's not the same. For one it "breaks" RETURNING which is a death
knell, for another it's not exactly obvious.

Greetings,

Andres Freund

In response to

Responses

Browse pgsql-admin by date

  From Date Subject
Next Message Natalie Wenz 2015-05-06 18:11:08 pg_dump: preserving oids in system tables?
Previous Message Payal Singh 2015-05-06 15:15:26 Re: Import csv file error with double newline

Browse pgsql-hackers by date

  From Date Subject
Next Message Robert Haas 2015-05-06 16:25:01 Re: Patch for bug #12845 (GB18030 encoding)
Previous Message Alvaro Herrera 2015-05-06 15:13:25 Re: Patch for bug #12845 (GB18030 encoding)