X-Original-To: pgsql-sql-postgresql.org@localhost.postgresql.org Received: from localhost (av.hub.org [200.46.204.144]) by postgresql.org (Postfix) with ESMTP id 0CA9B9DCC87 for ; Tue, 29 Nov 2005 10:37:42 -0400 (AST) Received: from postgresql.org ([200.46.204.71]) by localhost (av.hub.org [200.46.204.144]) (amavisd-new, port 10024) with ESMTP id 31661-04-2 for ; Tue, 29 Nov 2005 10:37:44 -0400 (AST) X-Greylist: from auto-whitelisted by SQLgrey- Received: from sss.pgh.pa.us (sss.pgh.pa.us [66.207.139.130]) by postgresql.org (Postfix) with ESMTP id 926D19DCB88 for ; Tue, 29 Nov 2005 10:37:38 -0400 (AST) Received: from sss2.sss.pgh.pa.us (tgl@localhost [127.0.0.1]) by sss.pgh.pa.us (8.13.1/8.13.1) with ESMTP id jATEbgw1006966; Tue, 29 Nov 2005 09:37:42 -0500 (EST) To: "Leif B. Kristensen" cc: pgsql-sql@postgresql.org Subject: Re: Strange bug In-reply-to: <200511291531.30441.leif@solumslekt.org> References: <200511291531.30441.leif@solumslekt.org> Comments: In-reply-to "Leif B. Kristensen" message dated "Tue, 29 Nov 2005 15:31:30 +0100" Date: Tue, 29 Nov 2005 09:37:42 -0500 Message-ID: <6965.1133275062@sss.pgh.pa.us> From: Tom Lane X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, score=0.004 required=5 tests=[AWL=0.004] X-Spam-Score: 0.004 X-Spam-Level: X-Archive-Number: 200511/270 X-Sequence-Number: 23521 "Leif B. Kristensen" writes: > I just noticed that I accidentally got a duplicate id. My > definitions are here: > CREATE TABLE citations ( > citation_id INTEGER PRIMARY KEY, > source_fk INTEGER REFERENCES sources (source_id) > ); > CREATE TABLE relation_citations ( > relation_fk INTEGER REFERENCES relations (relation_id) > ) INHERITS (citations); relation_citations doesn't have a primary key. See http://www.postgresql.org/docs/8.1/static/ddl-inherit.html particularly the "caveats" section. regards, tom lane