Source of User Defined functions.

Source of User Defined functions.

am 09.09.2008 22:49:40 von Saii

------=_Part_34292_20417436.1220993381019
Content-Type: text/plain; charset=ISO-8859-1
Content-Transfer-Encoding: 7bit
Content-Disposition: inline

Hello,

I have a questions regarding the location of source code of user defined
functions in Postgres. I used the following query to get all function names
but I
do not see the source code of the user defined functions. In the 'prosrc'
column, data is available for trigger functions only. Is there any other
table/column where function source code can be found?

SELECT p.proname, p.pronargs, t.typname,p.proowner, p.prosrc
FROM pg_proc p, pg_language l, pg_type t
WHERE p.prolang = l.oid
and p.prorettype = t.oid
and l.lanname in ('sql', 'plpgsql' )
and proowner = 964227
ORDER BY proname;


Thanks much
Saii

------=_Part_34292_20417436.1220993381019
Content-Type: text/html; charset=ISO-8859-1
Content-Transfer-Encoding: 7bit
Content-Disposition: inline

Hello,

  I have a questions regarding the location of source code of user defined functions in Postgres. I used the following query to get all function names but I
  do not see the source code of the user defined functions. In the 'prosrc' column, data is available for trigger functions only. Is there any other table/column where function source code can be found?


SELECT p.proname, p.pronargs, t.typname,p.proowner, p.prosrc
  FROM pg_proc p, pg_language l, pg_type t
  WHERE p.prolang = l.oid
    and p.prorettype = t.oid
    and l.lanname in ('sql', 'plpgsql'  )

    and proowner = 964227
  ORDER BY proname;


  Thanks much
  Saii



------=_Part_34292_20417436.1220993381019--

Re: Source of User Defined functions.

am 10.09.2008 00:04:21 von Alvaro Herrera

Saii escribi=F3:
> Hello,
>=20
> I have a questions regarding the location of source code of user defi=
ned
> functions in Postgres. I used the following query to get all function n=
ames
> but I
> do not see the source code of the user defined functions. In the 'pro=
src'
> column, data is available for trigger functions only. Is there any othe=
r
> table/column where function source code can be found?

prosrc is source for all plpgsql functions (and others). If you have C
functions, you cannot see the code because all we know is a shared
library to load and function name to call.

--=20
Alvaro Herrera http://www.CommandPrompt.co=
m/
The PostgreSQL Company - Command Prompt, Inc.

--=20
Sent via pgsql-admin mailing list (pgsql-admin@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-admin