Skip site navigation (1) Skip section navigation (2)

Re: Postgres Stored Procedure Call Function Return Type OID Caching Problem

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: "Feng Chen" <fchen(at)covergence(dot)com>
Cc: "imad" <immaad(at)gmail(dot)com>, pgsql-odbc(at)postgresql(dot)org
Subject: Re: Postgres Stored Procedure Call Function Return Type OID Caching Problem
Date: 2007-01-24 22:15:56
Message-ID: 9954.1169676956@sss.pgh.pa.us (view raw or flat)
Thread:
Lists: pgsql-odbc
"Feng Chen" <fchen(at)covergence(dot)com> writes:
> The problem is that I should not have to and cannot re-load the
> functions every now and then. Why would the type id change and the
> function still references to the old type id thus fails to get the right
> results?

It's not possible in any modern version of PG to drop the function's
return type without dropping the function too.  I suspect the problem
is not with the return type at all, but with some table or other type
referenced within the function body.  Currently the only real solution
to that is to use EXECUTE for every SQL command that touches a transient
object, so that plpgsql won't try to cache a plan for the command.

			regards, tom lane

In response to

Responses

pgsql-odbc by date

Next:From: Feng ChenDate: 2007-01-24 22:44:39
Subject: Re: Postgres Stored Procedure Call Function Return Type OID Caching Problem
Previous:From: Feng ChenDate: 2007-01-24 21:20:45
Subject: Re: Postgres Stored Procedure Call Function Return Type OID Caching Problem

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group