Re: Reg:lo_open error..pls help me

Поиск
Список
Период
Сортировка
От Michael Fuhr
Тема Re: Reg:lo_open error..pls help me
Дата
Msg-id 20060301161059.GA80123@winnie.fuhr.org
обсуждение исходный текст
Ответ на Re: Reg:lo_open error..pls help me  (Tom Lane <tgl@sss.pgh.pa.us>)
Список pgsql-admin
On Wed, Mar 01, 2006 at 11:03:12AM -0500, Tom Lane wrote:
> "sandhya" <sandhyar@amiindia.co.in> writes:
> >   But lo_open is returning -1(-ve value).
>
> Are you sure that's where it's failing?  The fragment you showed looks
> fine as far as it goes.  The most likely bet is you forgot to wrap it in
> a transaction (BEGIN/COMMIT commands), but that would result in a
> failure at the seek/write commands because the object wouldn't be open
> anymore.

lo_open() fails if it's not in a transaction.  The error from
PQerrorMessage is:

ERROR:  invalid large-object descriptor: 0

--
Michael Fuhr

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

Предыдущее
От: Tom Lane
Дата:
Сообщение: Re: Reg:lo_open error..pls help me
Следующее
От: "Jason Minion"
Дата:
Сообщение: Re: problem in sequence