Re: return can contains any row or record functions

Поиск
Список
Период
Сортировка
От Neil Conway
Тема Re: return can contains any row or record functions
Дата
Msg-id 1131569829.6884.152.camel@localhost.localdomain
обсуждение исходный текст
Ответ на Re: return can contains any row or record functions  ("Pavel Stehule" <pavel.stehule@hotmail.com>)
Ответы Re: return can contains any row or record functions  ("Pavel Stehule" <pavel.stehule@hotmail.com>)
Список pgsql-patches
On Tue, 2005-08-11 at 08:55 +0100, Pavel Stehule wrote:
> Sorry for my ugly english.

Sorry, I didn't understand your reply.

The problem is this:

- we need to find the TupleDesc of the function's expected return type
for tuple-returning functions

- we can't use estate->rsi for the RETURN case, at least as presently
implemented, because that is not always filled-out -- the example I gave
before shows how because we don't check for a compatible TupleDesc when
estate->rsi is NULL, we end up returning a value that is incompatible
with the function's declared return type

- therefore, we need to use some other way to get the TupleDesc of the
function's declared return type. Offhand I think we can use
estate->fn_rettype (plus the funcapi stuff for handling RECORDOID), but
I haven't had a chance to try it yet.

-Neil



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

Предыдущее
От: Tom Lane
Дата:
Сообщение: Re: Trivial permission problem with external-projects.sgml / and a typo in postgresql.conf.sample
Следующее
От: "Pavel Stehule"
Дата:
Сообщение: Re: return can contains any row or record functions