Received: from localhost (postgresql.org [64.49.215.8]) by postgresql.org (Postfix) with ESMTP id A94D8475ED4 for ; Fri, 8 Nov 2002 01:19:10 -0500 (EST) Received: from hotmail.com (f136.law12.hotmail.com [64.4.19.136]) by postgresql.org (Postfix) with ESMTP id 10A92475D12 for ; Fri, 8 Nov 2002 01:19:10 -0500 (EST) Received: from mail pickup service by hotmail.com with Microsoft SMTPSVC; Thu, 7 Nov 2002 22:19:09 -0800 Received: from 128.123.37.105 by lw12fd.law12.hotmail.msn.com with HTTP; Fri, 08 Nov 2002 06:19:09 GMT X-Originating-IP: [128.123.37.105] From: "Zhidian Du" To: pgsql-sql@postgresql.org Subject: No promany key in parent table, how to use delete cascade? Date: Thu, 07 Nov 2002 23:19:09 -0700 Mime-Version: 1.0 Content-Type: text/plain; format=flowed Message-ID: X-OriginalArrivalTime: 08 Nov 2002 06:19:09.0765 (UTC) FILETIME=[BFC76750:01C286EE] X-Virus-Scanned: by AMaViS new-20020517 X-Archive-Number: 200211/125 X-Sequence-Number: 10267 Dear All, I want to dreate a delete cascade in children tables. The primary key of parent table is oid, so when I create parent table, there is no apparetly key word "primary key". The problem jumps out. When I create child table using columnn constraint on delete, the SQL says: "PRIMARY KEY for referenced table "parent" not found" I do not need to specify the primary key since I am using oid. How can I get around this problem? Thanks. Zhidian Du _________________________________________________________________ MSN 8 with e-mail virus protection service: 2 months FREE* http://join.msn.com/?page=features/virus