Sorry, should have been more specific.
Version 8.1.0

update statement called from a bash script where $tbl is table name and $sch is schema name

update pg_class set reltriggers =
(select count(*) from pg_trigger where tgrelid =
(select oid from pg_class where relname = '$tbl' and relnamespace =
(select oid from pg_namespace where nspname = '$sch')))--should have been a limiting where clause here


Thanks,

Roger

Tom Lane wrote:
Roger Ging <roger@musicreports.com> writes:
  
I accidentally wrecked the pg_class table in a database by leaving off 
the where clause of an update statement when setting the reltriggers 
back to the count from pg_trigger after a bulk data load.
    

What was the *exact* update statement, and which PG version is this?

			regards, tom lane