Re: rename primary key

From: Guillaume Lelarge <guillaume(at)lelarge(dot)info>
To: Seb <spluque(at)gmail(dot)com>
Cc: pgsql-sql(at)postgresql(dot)org
Subject: Re: rename primary key
Date: 2010-01-27 14:19:00
Message-ID: 4B604B54.7010905@lelarge.info
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-sql

Le 15/01/2010 17:13, Seb a écrit :
> On Fri, 15 Jan 2010 07:35:17 +0100,
> Guillaume Lelarge <guillaume(at)lelarge(dot)info> wrote:
>
> [...]
>
>> Primary keys are constraints. They are enforced with an index, but
>> actually they are constraints. So we put them on the constraints
>> nodes.
>
>> There is the same behaviour for unique constraints.
>
> Thanks. Would there be any problem with listing the index used to
> enforce the primary key constraint in the Indexes node to let us know of
> its existence? In fact, psql does report it with the meta-command \d.
> It was somewhat confusing to see Indexes(0), and then having to rename
> an index to rename a primary key constraint.
>

Sorry, forgot to answer this mail.

It was asked a few times before, and AFAICT the answer is still the
same. It is a constraint before being an index. The fact that it is also
an index is an implementation detail. I understand this is confusing.

--
Guillaume.
http://www.postgresqlfr.org
http://dalibo.com

In response to

Browse pgsql-sql by date

  From Date Subject
Next Message John Lister 2010-01-29 22:24:34 Partitioning by letter question
Previous Message Tom Lane 2010-01-25 02:17:09 Re: clock command regression in pltcl?