Inserting exported bytea value

Поиск
Список
Период
Сортировка
От seiliki@so-net.net.tw
Тема Inserting exported bytea value
Дата
Msg-id 20100211121507.6EC5DF48063@m5.so-net.net.tw
обсуждение исходный текст
Ответы Re: Inserting exported bytea value  (Pavel Stehule <pavel.stehule@gmail.com>)
Список pgsql-general
I am trying to build SQL commands that insert values exported from a bytea column.  Output facilities do not escape
singlequotes for bytea column. As such, the built INSERT SQL can be invalid because single quotes can appear in values.
Forexample, the built (invalid) INSERT SQL command can look like this: 

INSERT INTO t1 VALUES ('ABC\\000C'DE');

Note the apostrophe between C and D.

Are there straight approaches to do this job using version 8.x?
Does the bytea hex export feature provided by version 9 help solve this problem?

Thank you in advance!

CN

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

Предыдущее
От: "Marc Mamin"
Дата:
Сообщение: COPY FROM wish list
Следующее
От: Pavel Stehule
Дата:
Сообщение: Re: Inserting exported bytea value