Re: BUG #2277: Can't Open Relation when returning data from a stored procedure

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: BUG #2277: Can't Open Relation when returning data from a stored procedure
Дата
Msg-id 16061.1140537400@sss.pgh.pa.us
обсуждение исходный текст
Ответ на BUG #2277: Can't Open Relation when returning data from a stored procedure  ("Andrew Nykolyn" <nykolyn@ngc.com>)
Список pgsql-bugs
"Andrew Nykolyn" <nykolyn@ngc.com> writes:
> When running a stored procedure that loads data into a temporary table, the
> following error occurs when returning the result set through a composite
> data type.
>     Could not open relation with OID 443748

It looks to me like you're running into the same issue described here:
http://archives.postgresql.org/pgsql-general/2006-02/msg00172.php
namely that a toasted datum is still in memory after the owning table
has been dropped, and so subsequent attempts to expand the datum fail.

I'm not sure there is any really nice fix for that --- the easy fix
of forcibly detoasting everything before plpgsql stores it anyplace
would have very unpleasant performance implications.  Needs more thought.

Curious that this behavior has been there unremarked since 7.1 or so
and now two different people stumble across it within a couple of weeks
of each other.

            regards, tom lane

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

Предыдущее
От: Peter Eisentraut
Дата:
Сообщение: Re: BUG #2261: ILIKE seems to be buggy on koi8 input
Следующее
От: Tom Lane
Дата:
Сообщение: Re: BUG #2274: Error in 'CREATE DOMAIN' SQL command in dump file