Re: Postgres unique index checking and atomic transactions

From: Dennis Gearon <gearond(at)cvc(dot)net>
To: Greg Stark <gsstark(at)mit(dot)edu>
Cc: Dmitry Tkach <dmitry(at)openratings(dot)com>, pgsql-general(at)postgresql(dot)org
Subject: Re: Postgres unique index checking and atomic transactions
Date: 2003-07-24 18:15:31
Message-ID: 3F202243.5070903@cvc.net
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

That sounds like a feature that would bring Postgres closer to Oracle in power and flexibility, (mind you, by an increment, not enough to do an advertisement campaign!)

Greg Stark wrote:
> Dmitry Tkach <dmitry(at)openratings(dot)com> writes:
>
>
>>The good news though is that, if you drop (or disable) your pk index
>
>
> That's what I did, except I had to cascade to the foreign keys and then
> recreate them too. And you can't really recreate a primary key constraint, you
> just get a unique index which I think is equivalent.
>
> And that's another wishlist item. It would be nice to be able to disable
> constraints without dropping them and without poking around in catalog tables
> manually.
>
> Ie, it would be nice to be able to do
>
> alter table foo disable constraint "$1"
>
> and then later do
>
> alter table foo enable constraint "$1"
>
> and have postgres optionally recheck the constraint or not. It would be a lot
> safer than potentially accidentally recreating the constraint incorrectly. And
> a lot safer than poking around in the catalog tables.
>

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Terence Chang 2003-07-24 18:18:03 How to encrypt data in Postgresql
Previous Message Jonathan Bartlett 2003-07-24 18:12:38 Re: SAP DB: The unsung Open Source DB