Re: two primairy key in one table ?

Поиск
Список
Период
Сортировка
От David A Dickson
Тема Re: two primairy key in one table ?
Дата
Msg-id Pine.LNX.4.33.0207051117150.9778-100000@blues.wcg.mcgill.ca
обсуждение исходный текст
Ответ на two primairy key in one table ?  (Angela Luyf <a.c.luyf@amc.uva.nl>)
Список pgsql-general
A tabe defined as
CREATE TABLE foobar (
 foo int,
 bar int,
 PRIMARY KEY (foo, bar) );

will allow many elements of type foo to be related to many elements of
type bar and vice versa. Each combiniation of foo and bar will be forced
unique.

On Thu, 4 Jul 2002, Angela Luyf wrote:

> Hello,
> I have a database model where a many to many relation is used, so i need
> to create a table with two primary key. Don't know how to solve this in
> postgress, can't find it in the tutorials, so can anybody help me with
> this ?
>
> A. Luyf

--
David A Dickson
david.dickson@mail.mcgill.ca




В списке pgsql-general по дате отправления:

Предыдущее
От: Thomas Lockhart
Дата:
Сообщение: Re: explicit cast error
Следующее
От: Shaun Thomas
Дата:
Сообщение: Re: Postgre vs MySQL