Copying large object in a stored procedure

Поиск
Список
Период
Сортировка
От Csaba Nagy
Тема Copying large object in a stored procedure
Дата
Msg-id 1208259052.8259.329.camel@PCD12478
обсуждение исходный текст
Ответы Re: Copying large object in a stored procedure
Список pgsql-general
Hi all,

Is there an easy way to copy a large object to a new one, having a new
OID and it's content independent from the original ?

The large object API functions would only allow to stream the original
to the client and stream it back to the server for the copy, which is
not really optimal... I would like to do it all on the server side. The
server side functions would work to export the original to a file and
then import it again, but that needs superuser privileges which rules
that out.

I could simply copy the contents of the pg_largeobject table, but then I
need  a new OID for that. I can use the server side large object API to
create an empty large object, delete it, then use the obtained OID for
the copy... but that also sounds somewhat suboptimal.

Is there any simple way to copy a large object ?

Cheers,
Csaba.




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

Предыдущее
От: Klint Gore
Дата:
Сообщение: Re: COPY to STDOUT and pipes
Следующее
От: Karsten Hilbert
Дата:
Сообщение: Re: Storage sizes for dates/times (documentation bug?)