Re: BUG #2511: violation of primary key on update with 2

From: Simon Riggs <simon(at)2ndquadrant(dot)com>
To: james <james(at)mercstudio(dot)com>
Cc: pgsql-bugs(at)postgresql(dot)org
Subject: Re: BUG #2511: violation of primary key on update with 2
Date: 2006-07-03 20:21:48
Message-ID: 1151958108.2479.305.camel@localhost.localdomain
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

On Mon, 2006-07-03 at 11:14 +0000, james wrote:

> i think it's a bug in postgresql ...

Primary Key constraints are not deferrable currently. This is a known
situation so this isn't a bug.

I would advise you not to update the PK of your tables. That usually
represents a modelling problem and so I'm not sure if people will spend
time on trying to make that work.

Use an indirect key or some other mechanism, such as Inserting into
another table and renaming them.

--
Simon Riggs
EnterpriseDB http://www.enterprisedb.com

In response to

Browse pgsql-bugs by date

  From Date Subject
Next Message Tomasz Ostrowski 2006-07-03 20:31:07 query very slow when enable_seqscan=on
Previous Message Phil Frost 2006-07-03 18:19:09 BUG #2512: pg_dump produces unrestorable output when table and serial sequence are not in the same schema