Re: references definition to multi-field primary key - Mailing list pgsql-sql

From Bruno Wolff III
Subject Re: references definition to multi-field primary key
Date
Msg-id 20020816155911.GA15999@wolff.to
Whole thread Raw
In response to references definition to multi-field primary key  (Gary Stainburn <gary.stainburn@ringways.co.uk>)
List pgsql-sql
On Fri, Aug 16, 2002 at 16:15:57 +0100, Gary Stainburn <gary.stainburn@ringways.co.uk> wrote:
> 
> I only want the insert to work if prpid matches pgpid and prnozzle matches 
> pgnozzle.

There are several typos in your sample that make it hard to know for
sure what you want to do. However I suspect you just want to add a
foreign key clause to your table definition. These can refer to more
than one column (unlike references). My memory is that you need a matching
unique index defined for the table you are referencing.


pgsql-sql by date:

Previous
From: Gary Stainburn
Date:
Subject: references definition to multi-field primary key
Next
From: "Alexander M. Pravking"
Date:
Subject: Results from EXECUTE