Skip site navigation (1) Skip section navigation (2)

foreign key violation

From: Larry Holish <ljholish(at)speakeasy(dot)net>
To: pgsql-novice(at)postgresql(dot)org
Subject: foreign key violation
Date: 2001-04-06 03:56:49
Message-ID: 20010405225649.A15371@badlands.philberts.org (view raw or flat)
Thread:
Lists: pgsql-novice
Hello,

I am inserting rows from a temp table into table A using INSERT INTO.
Table A has a foreign key referencing table B's primary key.  I get
the following error:

<unnamed> referential integrity violation - key referenced from table
A not found in table B

Is there a way to tell which row(s) is causing the problem?  I am
using ver. 7.02. Thanks in advance,

-- 
Larry Holish
<ljholish(at)speakeasy(dot)net>

Responses

pgsql-novice by date

Next:From: Peter LovellDate: 2001-04-06 08:14:58
Subject: FOR UPDATE NOWAIT
Previous:From: Tom LaneDate: 2001-04-05 22:16:48
Subject: Re: Re: Database Name Case Sensitivity

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group