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

Peripheral Links

Header And Logo

PostgreSQL
| The world's most advanced open source database.

Site Navigation

Search for
  Advanced Search

Re: How to add our functions in postgres


  • From: Martijn van Oosterhout <kleptog(at)svana(dot)org>
  • To: sandeep satpal <sandeep(at)it(dot)iitb(dot)ac(dot)in>
  • Cc: pgsql-hackers(at)postgresql(dot)org
  • Subject: Re: How to add our functions in postgres
  • Date: Wed, 30 Nov 2005 07:11:15 +0100
  • Message-id: <20051130061113(dot)GA23691(at)svana(dot)org>

On Wed, Nov 30, 2005 at 10:40:42AM +0530, sandeep satpal wrote:
> 
> Hi,
> I have to add a function in varlena.c named
> btcasecmp(PG_FUNCTION_ARG) ,
> so what other information I have to add in source.
> I know little bit of it,
> I have added that function in
> src/backend/utils/fmgrtab.c and assign a new oid but when I installed that 
> function definition is not appearing in the table "pg_amproc",
> So I want to know what other information I have to add so that I can call 
> my function using oid.

Is that the file with in large friendly letters says: DO NOT EDIT THIS
FILE!

It says: It has been GENERATED by Gen_fmgrtab.sh
         from ../../../src/include/catalog/pg_proc.h

So you need to add it to src/include/catalog/pg_proc.h

Obviously if you want it to appear in pg_amproc you probably also want
to change src/include/catalog/pg_amproc.h

Have a nice day,
-- 
Martijn van Oosterhout   <kleptog(at)svana(dot)org>   http://svana.org/kleptog/
> Patent. n. Genius is 5% inspiration and 95% perspiration. A patent is a
> tool for doing 5% of the work and then sitting around waiting for someone
> else to do the other 95% so you can sue them.

Attachment: pgpBOTM3VVqU1.pgp
Description: PGP signature



Home | Main Index | Thread Index

Privacy Policy | PostgreSQL Archives hosted by Command Prompt, Inc. | Designed by tinysofa
Copyright © 1996 – 2008 PostgreSQL Global Development Group