Re: can't delete because of constraint from zombie table

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Jaime Silvela <JSilvela(at)Bear(dot)com>
Cc: pgsql-general(at)postgresql(dot)org
Subject: Re: can't delete because of constraint from zombie table
Date: 2006-11-17 22:06:09
Message-ID: 21404.1163801169@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Jaime Silvela <JSilvela(at)Bear(dot)com> writes:
> I do
> delete from staging_deal where staging_deal_id = 1
> and get
> ERROR: update or delete on "staging_deal" violates foreign key
> constraint "staging_deal_fkey" on "staging_document"
> DETAIL: Key (staging_deal_id)=(1) is still referenced from table
> "staging_document".

> I try to find that table
> select * from staging_document
> but
> ERROR: relation "staging_document" does not exist

Sounds to me like "staging_document" is in a schema that is not in your
search path?

regards, tom lane

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Matt Miller 2006-11-17 22:26:37 Allowing SYSDATE to Work
Previous Message Tom Lane 2006-11-17 22:03:44 Re: Shutting down a warm standby database in 8.2beta3