Re: Foreign Unique Constraint

From: "Jon Horsman" <horshaq(at)gmail(dot)com>
To: pgsql-sql(at)postgresql(dot)org
Subject: Re: Foreign Unique Constraint
Date: 2007-03-27 14:27:18
Message-ID: 4f4c2a010703270727l28ad24c6if8881ad6253f9253@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-sql

> > create table table1 (
> > id SERIAL PRIMARY KEY
> > extension UNIQUE,
>
> I can't find anything about this syntax in the docs...

Oops, i'm missing a comma on that first line, should have been:

create table table1 (
id SERIAL PRIMARY KEY,
extension UNIQUE,
)

> I think, you should write a TRIGGER for this.

Ok, i'll look into how that works. Anyone have any other input?

Thanks,

Jon

In response to

Browse pgsql-sql by date

  From Date Subject
Next Message Tom Lane 2007-03-27 14:49:50 Re: array_to_string
Previous Message Peter Eisentraut 2007-03-27 14:20:08 Re: select vs. select count