Penguin <Mail@dempos.com> writes:
> I have added support of procedural language 'plpgsql' in
> postgres system table pg_language. Now when I try to insert a record
> in the emp table :
> insert into emp(empname, salary) values( 'test', 1000 );
> from psql I get the following error :
> psql:rec.sql:1:ERROR:frmgr_info:function 0:cache lookup failed
I copied-and-pasted your example, and it works fine for me on 7.0.*:
play=> insert into emp(empname, salary) values( 'test', 1000 );
INSERT 4576610 1
play=> insert into emp(empname, salary) values( 'test', -1);
ERROR: test cannot have a negative salary
I suspect you messed up the installation of 'plpgsql' somehow.
Did you use the createlang script for that, or do it by hand?
regards, tom lane