Re: naming a primary key possible?

From: Michael Glaesemann <grzm(at)seespotcode(dot)net>
To: Ow Mun Heng <Ow(dot)Mun(dot)Heng(at)wdc(dot)com>
Cc: pgsql-general(at)postgreSQL(dot)org
Subject: Re: naming a primary key possible?
Date: 2007-08-28 02:12:52
Message-ID: 4C33DFD1-E012-43FB-991C-A84F0D9E427A@seespotcode.net
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general


On Aug 27, 2007, at 20:50 , Ow Mun Heng wrote:

> Is it possible to name a primary key (composite) primary key rather
> than
> have pg default to table_name_pkey??
>
> I tried something like
>
> primary key pkey_table_short_form_name (a,b,c)

create table tab (col text, constraint col_is_pkey primary key (col));

http://www.postgresql.org/docs/8.2/interactive/sql-createtable.html

Michael Glaesemann
grzm seespotcode net

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Tom Lane 2007-08-28 02:18:59 Re: Tables dissapearing
Previous Message Erik Jones 2007-08-28 02:03:46 Re: naming a primary key possible?