Re: [INTERFACES] Postgresql + lo

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: [INTERFACES] Postgresql + lo
Дата
Msg-id 1300.931482974@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Postgresql + lo  (Florian Baumert <baumert@plt.de>)
Список pgsql-interfaces
Florian Baumert <baumert@plt.de> writes:
> What happens is that it writes a -1 to the screen and a database-error "ERROR: lo_lseek: invalid large obj descriptor
(0)"

This needs to go into the FAQ, I think, 'cause you're about the third
person to ask the same question in the past couple weeks.

You need to wrap a transaction ("begin" ... "commit") around any use
of a large object handle, ie any lo_open ... lo_close sequence.

This requirement has always been in the LO docs, but Postgres 6.5 is the
first release that enforces the rule (by closing all open LO handles at
end of statement, if not within a transaction).  In prior versions,
you could sometimes get away with not using a transaction, but it
was NOT reliable.
        regards, tom lane


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

Предыдущее
От: seb@Panther4095.eiu.edu
Дата:
Сообщение: NEW WEB INTERFACE for PostgreSQL
Следующее
От: Tom Lane
Дата:
Сообщение: Re: [INTERFACES] transactions in libpq++ require new connection?