Re: Return Record

Поиск
Список
Период
Сортировка
От Antti Haapala
Тема Re: Return Record
Дата
Msg-id Pine.GSO.4.55.0306081159190.25259@paju.oulu.fi
обсуждение исходный текст
Ответ на Re: Return Record  (Rory Campbell-Lange <rory@campbell-lange.net>)
Список pgsql-general
On Fri, 6 Jun 2003, Rory Campbell-Lange wrote:

> On 06/06/03, Rory Campbell-Lange (rory@campbell-lange.net) wrote:
> > I'm not clear on how to handle returning a record from a function.
> > I have planned a function that is handed two strings and returns two
> > integers. I need to return errors that satisfy the return type. At the
> > moment my "RETURN 0;" lines result in "return type mismatch..." errors.
>
> I've found a userful resource on postgresql.org:
>
> "PostgreSQL 7.3 Set Returning Functions":
> http://techdocs.postgresql.org/guides/SetReturningFunctions
>
> However I'm still having trouble living up to the title of the article!
>
> The error I'm getting is:
> temporary=> select fn_b1_login('email@email', 'pass');
> WARNING:  Error occurred while executing PL/pgSQL function fn_b1_login
> WARNING:  while casting return value to function's return type
> ERROR:  Set-valued function called in context that cannot accept a set

*sigh*

temporary=> select * from fn_b1_login('email@email', 'pass');

--
Antti Haapala

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

Предыдущее
От: "Ron Mayer"
Дата:
Сообщение: Re: [HACKERS] SAP and MySQL ... [and Benchmark]
Следующее
От: Sean Chittenden
Дата:
Сообщение: Re: Anonymous CVS access