Problem with returning setof record

Поиск
Список
Период
Сортировка
От oliverp21@free.fr
Тема Problem with returning setof record
Дата
Msg-id 1094577194.413dec2a05bc4@imp1-q.free.fr
обсуждение исходный текст
Ответы Re: Problem with returning setof record
Список pgsql-sql
Hello,

Here is a simple function I created for a test.

create function ttt() returns setof record as '
declare
r record;
begin
for r in select * from utilisateurs.menus loop  return next r;
end loop;
return;
end;
' language 'plpgsql';

When I try to use it, it returns to me :

select ttt();set-valued function called in context that cannot accept a set
:  PL/pgSQL function "ttt" line 5 at return next

Anyone has an idea ?

Best regards,
Patrice OLIVER


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

Предыдущее
От: Andreas Joseph Krogh
Дата:
Сообщение: Re: Problem with LATIN1 characters from Perl-DBI
Следующее
От: Richard Huxton
Дата:
Сообщение: Re: Problem with returning setof record