Re: returning multiple result sets from a stored procedure

From: Darren Duncan <darren(at)darrenduncan(dot)net>
To: PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: returning multiple result sets from a stored procedure
Date: 2010-09-10 05:02:14
Message-ID: 4C89BBD6.70707@darrenduncan.net
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Peter Eisentraut wrote:
> On tor, 2010-09-09 at 13:08 -0700, Darren Duncan wrote:
>> Since Pg's FUNCTION already seems to take on both roles, so
>> overloading the meaning of the FUNCTION keyword, like what a C
>> function or a Perl sub does, where returning VOID means procedure,
>> then what is being added by a distinct PROCEDURE?
>
> I'd just like to have the CALL statement, because
>
> CALL do_something();
>
> looks better than
>
> SELECT do_something();
>
> Small details ...

I don't have a problem with the PERFORM keyword aside from it being more verbose
than CALL, except that, with 8.4 anyway, PERFORM doesn't seem to work
client-side. It seems that to invoke a VOID function foo client-side I still
have to say "SELECT foo(...);" because saying "PERFORM foo(...);" is
unfortunately a syntax error. -- Darren Duncan

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Tom Lane 2010-09-10 05:51:58 Re: git: uh-oh
Previous Message Peter Eisentraut 2010-09-10 04:49:16 Re: returning multiple result sets from a stored procedure