Re: No implicit index created when adding primary key with ALTER TABLE - Mailing list pgsql-general

From Tom Lane
Subject Re: No implicit index created when adding primary key with ALTER TABLE
Date
Msg-id 10127.1308091183@sss.pgh.pa.us
Whole thread Raw
In response to Re: No implicit index created when adding primary key with ALTER TABLE  (Stefan Keller <sfkeller@gmail.com>)
Responses Re: No implicit index created when adding primary key with ALTER TABLE  (Stefan Keller <sfkeller@gmail.com>)
List pgsql-general
Stefan Keller <sfkeller@gmail.com> writes:
> My explanation is that the message (saying that an index was
> implicitly created) is simply wrong.

The correct explanation is that you're misinterpreting whatever output
you're looking at.  Every unique or pkey constraint has an underlying
index --- the index is the implementation mechanism for the constraint,
so this is assuredly so.  Some tools that show both constraints and
indexes will omit constraint-associated indexes from the listing, since
otherwise they'd be showing duplicate information.

            regards, tom lane

pgsql-general by date:

Previous
From: Stefan Keller
Date:
Subject: Re: No implicit index created when adding primary key with ALTER TABLE
Next
From: Adrian Klaver
Date:
Subject: Re: No implicit index created when adding primary key with ALTER TABLE