inheritance and foreign key

From: "Kancha (dot)" <kancha2np(at)yahoo(dot)com>
To: pgsql-general(at)postgresql(dot)org
Cc: pgsql-sql(at)postgresql(dot)org
Subject: inheritance and foreign key
Date: 2002-02-19 15:17:04
Message-ID: 20020219151704.13896.qmail@web14908.mail.yahoo.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general pgsql-sql

I'm a postgresql newbie.

It seems that primary key is not inherited by tables.
My situtation is as follows

I've a parent table and child tables with inherit from
parent table. Parent table consists of pid (defualt
value of pid is from sequence) that is primary key.
Now all child tables inherits this attribute pid.

I've another table from where i reference this pid as:

pid integer references parent (pid)

the table creation is successful, but when i try to
insert data into this table that refereces parent
table i get error - something like the referenced
column doesn't exist.

I'm using version 7.1 in RH Linux 7.2 box.

__________________________________________________
Do You Yahoo!?
Yahoo! Sports - Coverage of the 2002 Olympic Games
http://sports.yahoo.com

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Roy Cabaniss 2002-02-19 15:29:47 Av "OID" ing working
Previous Message Dave Cramer 2002-02-19 15:13:46 Courier Industry packages

Browse pgsql-sql by date

  From Date Subject
Next Message Hunter, Ray 2002-02-19 16:03:51 Postgres vs. Mysql
Previous Message Tom Lane 2002-02-19 14:54:57 Re: Transient Disk Usage Higher In 7.2 ?