Re: [HACKERS] Re: [SQL] SQL-Query 2 get primary key - Mailing list pgsql-hackers

From Thomas G. Lockhart
Subject Re: [HACKERS] Re: [SQL] SQL-Query 2 get primary key
Date
Msg-id 36CEE00F.CCAA0DAB@alumni.caltech.edu
Whole thread Raw
In response to Re: [SQL] SQL-Query 2 get primary key  ("D'Arcy" "J.M." Cain <darcy@druid.net>)
List pgsql-hackers
> > if I create a table like this:
> > CREATE TABLE test (
> >    id decimal(3) primary key,
> >    name varchar(32));
<snip>
> Note that this makes the assumption that only one field can be in the
> primary key (no complex primary keys) but I don't think there will
> ever be more than one the way we declare it now.

fyi, the following syntax is allowed:
 CREATE TABLE test (    id decimal(3),    name varchar(32),    primary key(id));

and multiple columns can be declared as primary keys.
                      - Tom


pgsql-hackers by date:

Previous
From: Hannu Krosing
Date:
Subject: A few questions (was: SQL-Query 2 get primary key)
Next
From: "Daryl W. Dunbar"
Date:
Subject: RE: [HACKERS] Major bug, possible, with Solaris 7?