Re: foreign key constraints, cannot delete - Mailing list pgsql-general

From Michael Fuhr
Subject Re: foreign key constraints, cannot delete
Date
Msg-id 20041009001450.GA61983@winnie.fuhr.org
Whole thread Raw
In response to Re: foreign key constraints, cannot delete  (Josh Close <narshe@gmail.com>)
Responses Re: foreign key constraints, cannot delete [SOLVED]
List pgsql-general
On Fri, Oct 08, 2004 at 04:21:01PM -0500, Josh Close wrote:
> On Fri, 8 Oct 2004 23:15:24 +0200, Martijn van Oosterhout
> <kleptog@svana.org> wrote:
> > You havn't posted the exact error message. You'll have to if you want
> > people to properly explain what's going on...
>
> update or delete on "tblheadings" violates foreign key constraint "$1"
> on "tblheadings" DETAIL: Key (iid)=(22) is still referenced from table
> "tblheadings"

This looks like tblheadings has a foreign key reference to itself.
Is this the *exact* error message, cut-and-pasted?  What do your
table definitions look like?

--
Michael Fuhr
http://www.fuhr.org/~mfuhr/

pgsql-general by date:

Previous
From: Josh Close
Date:
Subject: Re: foreign key constraints, cannot delete
Next
From: Josh Close
Date:
Subject: Re: foreign key constraints, cannot delete [SOLVED]