Re: conditional insert - Mailing list pgsql-general

From Andrew Sullivan
Subject Re: conditional insert
Date
Msg-id 20110907200454.GV35347@shinkuro.com
Whole thread Raw
In response to Re: conditional insert  (Merlin Moncure <mmoncure@gmail.com>)
Responses Re: conditional insert  (Merlin Moncure <mmoncure@gmail.com>)
Re: conditional insert  (Lincoln Yeoh <lyeoh@pop.jaring.my>)
List pgsql-general
On Wed, Sep 07, 2011 at 02:51:32PM -0500, Merlin Moncure wrote:
>
> @andrew s: going SERIALIZABLE doesn't help if you trying to eliminate
> cases that would push you into retrying the transaction.

Well, no, of course.  But why not catch the failure and retry?  I
guess I just don't get the problem, since I hear people say this all
the time.  (I mean, I've also seen places where 'upsert' would be
cool, but it doesn't seem trivial to do in a general way and you can
do this with catch-serialization-error-and-retry, I think?)

A

--
Andrew Sullivan
ajs@crankycanuck.ca

pgsql-general by date:

Previous
From: Merlin Moncure
Date:
Subject: Re: conditional insert
Next
From: Merlin Moncure
Date:
Subject: Re: conditional insert