Re: Create Foriegn Key - Mailing list pgsql-general

From Stephan Szabo
Subject Re: Create Foriegn Key
Date
Msg-id 20030606201333.W45663-100000@megazone23.bigpanda.com
Whole thread Raw
In response to Create Foriegn Key  ("David Busby" <busby@pnts.com>)
List pgsql-general
On Wed, 4 Jun 2003, David Busby wrote:

> List,
>     How can I create a Foriegn Key after my table is created?  I cannot find
> in docs (or google) anywhere.

See ALTER TABLE ADD CONSTRAINT, generally something of the form:

ALTER TABLE tablename ADD CONSTRAINT constraint name FOREIGN KEY(fkcol1)
 REFERENCES pktable(pkcol1);



pgsql-general by date:

Previous
From: Tom Lane
Date:
Subject: Re: Optimizer failure on integer column?
Next
From: Jeff Fitzmyers
Date:
Subject: Re: Create Foriegn Key