Re: [GENERAL] Possible bug: could not open relation with OID [numbers] SQL State: XX000

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: [GENERAL] Possible bug: could not open relation with OID [numbers] SQL State: XX000
Дата
Msg-id 13901.1509586595@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Re: [GENERAL] Possible bug: could not open relation with OID[numbers] SQL State: XX000  (Adam Brusselback <adambrusselback@gmail.com>)
Ответы Re: [GENERAL] Possible bug: could not open relation with OID[numbers] SQL State: XX000  (Adam Brusselback <adambrusselback@gmail.com>)
Список pgsql-general
Adam Brusselback <adambrusselback@gmail.com> writes:
> The OID does not match any of the temp tables, so not sure what's up there.
> I have the function RETURN QUERY,
> and then I drop all my temp tables.

I'll bet the OID corresponds to the toast table for one of those temp
tables.  RETURN QUERY will stash away all the values read by the query,
but it doesn't make an attempt to inline out-of-line values; so you get
a failure when the out-of-line column value is eventually demanded.

I think we've seen one previous complaint of the same ilk.  Probably
somebody will get annoyed enough to fix it at some point, but the
sticking point is how to cover this corner case without causing a
performance drop for normal cases.  In the meantime, maybe you could
make the temp tables be ON COMMIT DROP instead of dropping them
explicitly mid-transaction.
        regards, tom lane


-- 
Sent via pgsql-general mailing list (pgsql-general@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general

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

Предыдущее
От: Adam Brusselback
Дата:
Сообщение: Re: [GENERAL] Possible bug: could not open relation with OID[numbers] SQL State: XX000
Следующее
От: Adam Brusselback
Дата:
Сообщение: Re: [GENERAL] Possible bug: could not open relation with OID[numbers] SQL State: XX000