Re: Converting non-null unique idx to pkey - Mailing list pgsql-general

From Ed L.
Subject Re: Converting non-null unique idx to pkey
Date
Msg-id 200708221107.41418.pgsql@bluepolka.net
Whole thread Raw
In response to Re: Converting non-null unique idx to pkey  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-general
On Tuesday 21 August 2007 11:40 pm, Tom Lane wrote:
> "Ed L." <pgsql@bluepolka.net> writes:
> > Are there
> > are any known or obvious gotchas associated with
> > transforming a unique index on a non null column into a
> > primary key via this sql?
> >
> > update pg_index
> > set indisprimary = 't'
> > where indexrelid = <my non-null unique index oid>
>
> The problem with that is there won't be any pg_constraint
> entry, nor any pg_depend entries linking to/from the
> constraint...

Thanks.  Sounds messy enough, I'll try another route.

Ed

pgsql-general by date:

Previous
From: "Scott Marlowe"
Date:
Subject: Re: Postgres, fsync and RAID controller with 100M of internal cache & dedicated battery
Next
From: Christian Schröder
Date:
Subject: "out of memory" error