Return-Path: mao
Received: by postgres.Berkeley.EDU (5.61/1.29)
	id AA12294; Tue, 18 Aug 92 12:32:52 -0700
Message-Id: <9208181932.AA12294@postgres.Berkeley.EDU>
From: <mao@postgres.berkeley.edu>
Subject: Re: Strange replace behaviour (BUG)
To: postgres@postgres.berkeley.edu
Sender: pg_adm@postgres.berkeley.edu
In-Reply-To: Your message of Tue, 18 Aug 92 13:36:05 +0700.
             <9208181130.AA07803@postgres.Berkeley.EDU> 
Date: Tue, 18 Aug 92 12:33:08 PDT

In message <9208181130.AA07803@postgres.Berkeley.EDU> you write:

> I'v encountered a strange bug in postgres. I've defined
> a function as follows:
> 	[ ... ]
> but when I replace the pronargs atrtribute like: 
> 
> replace pg_proc (pronargs = 2) where pg_proc.proname = "reactinsert"
>	[ ... ]
>      | (null)      | (null)      | (null)      | (null)      | (null)      |
> 
> A number of attributes has changed too. Is this a bug or something else?

vincent,

this is a bug in the system catalogs for postgres 4.0 that has been
fixed in the current system.  the problem is that the number of attributes
recorded for pg_proc in pg_class is wrong.  if you do

    retrieve (pg_class.relnatts) where pg_class.relname = "pg_proc"

you'll see that only eleven attributes are declared.  this should be
sixteen.  you should be able to repair the problem by doing

    replace pg_class (relnatts = 16) where pg_class.relname = "pg_proc"

and killing and restarting your postmaster.  you should do this in
each database you have created, and you should do it in the template1
database.  changing template1 will cause all future databases you
create to have the right value.

					mike
