pg.ddx.io  pgsql-interfaces@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Ross J. Reedstrom <reedstrm@wallace.ece.rice.edu>
To: Karel Zak - Zakkr <zakkr@zf.jcu.cz>
Cc: Bryan White <bryan@arcamax.com>
Cc: pgsql-interfaces@postgresql.org
Subject: Re: [INTERFACES] The persistance of C functions
Date: Thu, 10 Feb 2000 10:34:50 -0600
Message-ID: <20000210103450.A8610@rice.edu> (raw)
In-Reply-To: <Pine.LNX.3.96.1000210103409.21359B-100000@ara.zf.jcu.cz>
References: <00bb01bf7344$fe1dcf00$2dd260d1@arcamax.com>
	<Pine.LNX.3.96.1000210103409.21359B-100000@ara.zf.jcu.cz>

On Thu, Feb 10, 2000 at 10:42:29AM +0100, Karel Zak - Zakkr wrote:
> 
> On Wed, 9 Feb 2000, Bryan White wrote:
> 
> > If I use CREATE FUNCTION for a C function in a .so file and then use the
> > function and then change and recompile the function, what steps are needed
> > to see the change?
> > 
> > As I see it the options are:
> > A: do nothing, the function is reloaded on every invocation.
> > B: Reopen the connection to the backend
> > C: Restart the postmaster
> > 
> > I suspect B is correct but I would like to hear someone confirm it.
> 
> 
>  'B' is right - the postgreSQL not has any persisten cache for this, and 
> if you restart connection a backend reload this information again.
> 
> Or you can drop/(re)create a function, it is total safe solution.


Not _totally_ safe: if you've got anything that refers to that function,
like a user defined type definition, drop/(re)create will change the
function's oid in the pg_proc table, causing errors when the old
function is looked up. Hmm, an ALTER FUNCTION command might be nice...

Ross
-- 
Ross J. Reedstrom, Ph.D., <reedstrm@rice.edu> 
NSBRI Research Scientist/Programmer
Computer and Information Technology Institute
Rice University, 6100 S. Main St.,  Houston, TX 77005



view thread (7+ messages)  latest in thread

Message-ID: <20000210103450.A8610@rice.edu>
Permalink:  ../20000210103450.A8610@rice.edu/
Also on:    postgresql.org/message-id/20000210103450.A8610@rice.edu

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: pgsql-interfaces@postgresql.org
  Cc: reedstrm@wallace.ece.rice.edu, zakkr@zf.jcu.cz, bryan@arcamax.com
  Subject: Re: [INTERFACES] The persistance of C functions
  In-Reply-To: <20000210103450.A8610@rice.edu>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox