From: | elein <elein(at)varlena(dot)com> |
---|---|
To: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
Cc: | John Hansen <john(at)geeknet(dot)com(dot)au>, pgsql-hackers(at)postgresql(dot)org |
Subject: | Re: CREATE or REPLACE function pg_catalog.* |
Date: | 2004-11-10 17:56:58 |
Message-ID: | 20041110095658.A7872@cookie.varlena.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
Isn't there a load/unload function for the .so that would work
in this case?
--elein
On Wed, Nov 10, 2004 at 12:11:27PM -0500, Tom Lane wrote:
> John Hansen <john(at)geeknet(dot)com(dot)au> writes:
> > When doing CREATE or REPLACE FUNCTION of a builtin function, it seems to
> > have no effect if its in the 'C" language. SQL functions seem to work,
> > but as neilc pointed out, it may be due to the SQL function being
> > inlined.
> > The builtin function is still called, not the userdefined function for
> > 'C' language functions.
>
> You can't override a builtin C function that way because there is a
> built-in map from function OID to builtin function address, and it's
> consulted before trying to look in pg_proc.
>
> This behavior is not really open to negotiation; not only on grounds of
> speed, but on grounds of circularity. (The functions used in the
> process of looking up entries in pg_proc itself obviously must have such
> a short circuit...) You'd have to build a modified backend in which the
> particular functions you want to replace are not listed in the builtin
> mapping table.
>
> regards, tom lane
>
> ---------------------------(end of broadcast)---------------------------
> TIP 2: you can get off all lists at once with the unregister command
> (send "unregister YourEmailAddressHere" to majordomo(at)postgresql(dot)org)
>
From | Date | Subject | |
---|---|---|---|
Next Message | Tom Lane | 2004-11-10 18:04:36 | Re: CREATE or REPLACE function pg_catalog.* |
Previous Message | Tom Lane | 2004-11-10 17:15:02 | Re: sp-gist porting to postgreSQL |