Re: KEY or INDEX

From: Bruno Wolff III <bruno(at)wolff(dot)to>
To: tövis <tovises(at)freemail(dot)hu>
Cc: pgsql novice <pgsql-novice(at)postgresql(dot)org>
Subject: Re: KEY or INDEX
Date: 2005-05-03 20:29:08
Message-ID: 20050503202908.GA8338@wolff.to
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-novice

On Tue, May 03, 2005 at 11:57:31 +0200,
tövis <tovises(at)freemail(dot)hu> wrote:
> Hi All
> Seem to be that I can not create KEY exclude PRIMARY and FOREIGN.
> This means for one table I can create only one key.
> All other, frequently used operations (browse, search) should use INDEX-es (may be unique).
> Is these statemens are correct?

The FOREIGN KEY clause doesn't create keys.

You can use UNIQUE and NOT NULL clauses to create candidate keys.

In response to

Browse pgsql-novice by date

  From Date Subject
Next Message Tom Lane 2005-05-03 20:43:19 Re: retrieving a previously defined stored procedure from the database?
Previous Message Volkan YAZICI 2005-05-03 20:17:29 Re: Can't Use DB As Template - accessed by other users error