Re: accessing functions in the core

From: Euler Taveira de Oliveira <euler(at)timbira(dot)com>
To: sushant354(at)gmail(dot)com
Cc: pgsql-hackers(at)postgresql(dot)org
Subject: Re: accessing functions in the core
Date: 2008-05-27 03:28:40
Message-ID: 483B7FE8.1060803@timbira.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Sushant Sinha wrote:

> I would like to create functions in the core and then access it.
> However, I do not know how to do it. Looks like all functions in the
> core are not accessible from outside. For example ts_headline_opt which
> is there in the core seems to be not present in pg_catalog.
> This is the query I used to test:
>
This is the wrong list to ask this kind of question. Try -general next time.
Indeed, the function name doesn't need to have the same name defined in
C code [1]. As you can see below, ts_headline_opt is called ts_headline
with 3 arguments.

euler=# select proname,prosrc,provolatile,pronargs from pg_proc where
proname ~ 'ts_headline';
proname | prosrc | provolatile | pronargs
-------------+----------------------+-------------+----------
ts_headline | ts_headline_byid_opt | i | 4
ts_headline | ts_headline_byid | i | 3
ts_headline | ts_headline_opt | s | 3
ts_headline | ts_headline | s | 2
(4 registros)

[1] http://www.postgresql.org/docs/8.3/static/sql-createfunction.html

--
Euler Taveira de Oliveira
http://www.timbira.com/

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Tatsuo Ishii 2008-05-27 03:40:58 Re: WITH RECURSIVE patches V0.1 TODO items
Previous Message Sushant Sinha 2008-05-27 02:36:33 accessing functions in the core