Re: 9.1/9.2 SERIALIZABLE: expected serialization failure between INSERT and SELECT not encountered

From: Chris Angelico <rosuav(at)gmail(dot)com>
To: pgsql-general(at)postgresql(dot)org
Subject: Re: 9.1/9.2 SERIALIZABLE: expected serialization failure between INSERT and SELECT not encountered
Date: 2012-10-18 07:22:57
Message-ID: CAPTjJmr+_eOmp-Bp3A4PLHU+WGFZO+ZeupVYJ-eiJ+QJ4SweSA@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

On Thu, Oct 18, 2012 at 3:08 PM, Craig Ringer <ringerc(at)ringerc(dot)id(dot)au> wrote:
> BTW, the issue with the underlying question is that their "name" column is
> unique. They expected to get a serialization failure on duplicate insert
> into "name", not a unique constraint violation. The question wasn't "why
> doesn't this fail" but "Why does this fail with a different error than I
> expected". Not that the question made that particularly clear.

Sounds to me like it's giving a better error anyway - more helpful to
know _why_ the second transaction failed than to simply know _that_ it
failed.

I've actually never used serializable transaction isolation,
preferring more explicit constraints.

ChrisA

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Kevin Grittner 2012-10-18 12:26:32 Re: 9.1/9.2 SERIALIZABLE: expected serialization failure between INSERT and SELECT not encountered
Previous Message Albe Laurenz 2012-10-18 07:10:15 Re: 9.1/9.2 SERIALIZABLE: expected serialization failure between INSERT and SELECT not encountered