pg.ddx.io  pgsql-php@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Mauri Sahlberg <Mauri.Sahlberg@pretax.net>
To: Markus Post <mpost@purematic.com>
Cc: pgsql-php@postgresql.org
Subject: Re: PL/PGSQL
Date: 28 Feb 2003 08:00:51 +0200
Message-ID: <1046412050.22290.10.camel@bushido.intra.pretax.net> (raw)
In-Reply-To: <000101c2de8e$3b595df0$8100a8c0@lucky>
References: <000101c2de8e$3b595df0$8100a8c0@lucky>

Hello,

On to, 2003-02-27 at 20:29, Markus Post wrote:
>     Hello together!
> 
> I have a little question, because I found the answer nowhere in the Net.
> How I can call a stored pl/pgsql-function from my SQL-Client.
> In an SQL-statement I call it like "select MYFUNCTION(blah, blah) from
> ...".
> I need it without the SQL-Statement.
> 
> In Oracle I would be:
> BEGIN
>    MYFUNCTION(...);
> END;
> 

You're probably looking from the wrong place. At least the answer can be
found from
http://www.postgresql.org/docs/view.php?version=7.3&idoc=0&file=plpgsql-statements.html

On that page, heading 19.5.3 states that you can do:

	PERFORM MYFUNCTION(...); 

if you wish to discard the return value. 
Or if your function returns something then you do:

	myresult:=MYFUNCTION(...);

Regards,
-- 
Development Manager, B.SC    | This message is probably digitally 
Pretax Systems Oy            | signed as well. Contact me to obtain my
Pääskylänrinne 8,            | public key.
FIN-00500-Helsinki, Finland  | This signature has performed an illegal
+358 9 6155 3252             | operation and will be terminated...

Attachments:

  signature.asc (application/pgp-signature, 188B) download

view thread (3+ messages)  latest in thread

Message-ID: <1046412050.22290.10.camel@bushido.intra.pretax.net>
Permalink:  ../1046412050.22290.10.camel@bushido.intra.pretax.net/
Also on:    postgresql.org/message-id/1046412050.22290.10.camel@bushido.intra.pretax.net

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-php@postgresql.org
  Cc: Mauri.Sahlberg@pretax.net, mpost@purematic.com
  Subject: Re: PL/PGSQL
  In-Reply-To: <1046412050.22290.10.camel@bushido.intra.pretax.net>
  References: <000101c2de8e$3b595df0$8100a8c0@lucky> <1046412050.22290.10.camel@bushido.intra.pretax.net>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox