Re: Full Stored Procedure Support, any time soon ?

Поиск
Список
Период
Сортировка
От Thomas Kellerer
Тема Re: Full Stored Procedure Support, any time soon ?
Дата
Msg-id l7dobh$4qu$1@ger.gmane.org
обсуждение исходный текст
Ответ на Re: Full Stored Procedure Support, any time soon ?  (Alban Hertroys <haramrae@gmail.com>)
Ответы Re: Full Stored Procedure Support, any time soon ?
Список pgsql-general
Alban Hertroys wrote on 30.11.2013 22:34:
>> - Multiple result sets
>
> Since you’re talking about procedures, you can’t possibly mean that those return multiple result sets?

Yes, basically something like this:

create procedure foobar()
begin
   select * from table_1;
   select * from table_2
end;

I know that at least SQL Server and MySQL can do that. Maybe others as well (Sybase most probably).

But I always failed do see the actual advantage of that because the results can't be "used" any further (e.g. in a JOIN
ora subselect). 
I also don't understand why having a single procedure doing a lot of stuff is better than having several procedures (or
functions)doing one defined thing. 

 From a JDBC point of view the code simply asks the Statement whether it has any more result sets
and loops over this until all results are returned.

Thomas

В списке pgsql-general по дате отправления:

Предыдущее
От: Noel Diaz
Дата:
Сообщение: Re: Full Stored Procedure Support, any time soon ?
Следующее
От: Noel Diaz
Дата:
Сообщение: Re: Full Stored Procedure Support, any time soon ?