Re: foreign key lost

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: mikeo <mikeo(at)spectrumtelecorp(dot)com>
Cc: pgsql-general(at)postgresql(dot)org
Subject: Re: foreign key lost
Date: 2000-07-07 18:34:48
Message-ID: 11325.962994888@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

mikeo <mikeo(at)spectrumtelecorp(dot)com> writes:
> hi, i accidently deleted a foreign key trigger from pg_trigger

Did you reach into pg_trigger and delete the record yourself, or did
a system bug cause the problem?

> and now cannot get at the table. i get the message:
> ERROR: RelationBuildTriggers: 1 record(s) not found for rel feature_code
> can anyone give me a shovel :)
> or a little help to get out of this please?

You'll need to tweak the table's pg_class entry so that its reltriggers
column shows the same number of triggers that are actually there for it
in pg_trigger. A quick "UPDATE pg_class" should get you out of it.

regards, tom lane

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message mikeo 2000-07-07 18:51:27 Re: foreign key lost
Previous Message mikeo 2000-07-07 18:25:15 foreign key lost