Re: Dual Primary keys

From: Bruno Wolff III <bruno(at)wolff(dot)to>
To: Bantamess <bantamess(at)yahoo(dot)co(dot)uk>
Cc: pgsql-novice(at)postgresql(dot)org
Subject: Re: Dual Primary keys
Date: 2004-02-04 15:35:18
Message-ID: 20040204153518.GA20727@wolff.to
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-novice

On Wed, Feb 04, 2004 at 15:15:45 -0000,
Bantamess <bantamess(at)yahoo(dot)co(dot)uk> wrote:
> Hello can any body tell me how to code a table with dual primary keys? The table 'borrower' has two PKs each one has been used in other tables within the same schema as single PKs

Use UNIQUE and NOT NULL constraints on one of the two keys. In references
to that key, you will need to specify the column name as the default
column name is the primary key.

In response to

Browse pgsql-novice by date

  From Date Subject
Next Message Tom Lane 2004-02-04 16:22:06 Re: Dual Primary keys
Previous Message Bantamess 2004-02-04 15:15:45 Dual Primary keys