Thanks Stephan! your suggestion works. I just wonder that if dropping
triggers caused such problem, this might be a postgres bug.

Anna Zhang

-----Original Message-----
From: Stephan Szabo [mailto:[EMAIL PROTECTED]]
Sent: Friday, March 08, 2002 1:02 PM
To: Zhang, Anna
Cc: '[EMAIL PROTECTED]'
Subject: Re: [ADMIN] vacuum error



On Fri, 8 Mar 2002, Zhang, Anna wrote:

> Hi,
> I got an error when vacuum database, see below:
>
> $vacuumdb xdap
> ERROR: RelationBuildTriggers: 2 record(s) not found for rel domain.
>
> I deleted triggers that referenced domain before vacuum, is this the
cause?
> How can I fix it? or It doesn't bother, It's ok to ignore such error?

It will be a problem. Update the pg_class row associated with domain to
fix the value of reltriggers, something like:
update pg_class set reltriggers=(select count(*) from pg_trigger
 where tgrelid=pg_class.oid) where relname='domain';

---------------------------(end of broadcast)---------------------------
TIP 6: Have you searched our list archives?

http://archives.postgresql.org

Reply via email to