adding procedural languages

Started by Sibtay Abbasabout 21 years ago2 messages
#1Sibtay Abbas
sibtay_abbas@yahoo.com

hi everyone

ok i ve tried to add my own procedural language using
the call handler interface.

I am doining nothing in the handler function except
tyring to print a mess through errmsg function
(plz correct me if i am wrong here, since i cant see
the message which i am printing)

Now my question is that how can i explicitly specify
that i want my pl language to be used.

I think i have added my language successfully by
following the procedure mentioned in the
documentation.

So now how do i inform the database engine to use my
language for a specific query

thank you

__________________________________
Do you Yahoo!?
Yahoo! Mail - Helps protect you from nasty viruses.
http://promotions.yahoo.com/new_mail

#2Andrew Dunstan
andrew@dunslane.net
In reply to: Sibtay Abbas (#1)
Re: adding procedural languages

Sibtay Abbas wrote:

hi everyone

ok i ve tried to add my own procedural language using
the call handler interface.

I am doining nothing in the handler function except
tyring to print a mess through errmsg function
(plz correct me if i am wrong here, since i cant see
the message which i am printing)

Now my question is that how can i explicitly specify
that i want my pl language to be used.

I think i have added my language successfully by
following the procedure mentioned in the
documentation.

So now how do i inform the database engine to use my
language for a specific query

Is this part of an academic project or something? Frankly, it looks to
me like you need to acquire a lot of basic knowledge about how
postgresql works internally before you even start thinking about what
you are trying to do.

Serverside PLs can only be used in user-defined functions, and the
language used is specified in the function definition, as in

create function foo() returns text language mypl as $$ <code in mypl> $$;

cheers

andrew