From: | Richard Broersma Jr <rabroersma(at)yahoo(dot)com> |
---|---|
To: | gustavo halperin <ggh(dot)develop(at)gmail(dot)com>, pgsql-general(at)postgresql(dot)org |
Subject: | Re: REFERENCE problem with parent_table |
Date: | 2006-08-15 17:52:47 |
Message-ID: | 20060815175247.26184.qmail@web31802.mail.mud.yahoo.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-general |
> I need many tables of type "id" and "name", see below:
> / CREATE TABLE id_names (
> id smallint CONSTRAINT the_id PRIMARY KEY NOT NULL,
> name text CONSTRAINT the_name UNIQUE
> ) WITH OIDS;/
> therefore I created these tables with the "LIKE" operator, see below:
> / CREATE TABLE like_id_1( LIKE id_names INCLUDING DEFAULTS ) WITH OIDS;
> CREATE TABLE like_id_2 ( LIKE id_names INCLUDING DEFAULTS ) WITH OIDS;
it looks like the syntax here is a little off from what is defined by:
http://www.postgresql.org/docs/8.1/interactive/sql-createtable.html
CREATE TABLE like_id_1 ( id smallint like id_names,
name text like id_name ) with oids ;
Regards,
Richard Broersma jr.
From | Date | Subject | |
---|---|---|---|
Next Message | shaun.ricci | 2006-08-15 18:19:39 | Changing the data directory Ubuntu |
Previous Message | gustavo halperin | 2006-08-15 17:39:07 | REFERENCE problem with parent_table |