Search Postgresql Archives

Inserting exported bytea value

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



I am trying to build SQL commands that insert values exported from a bytea column.  Output facilities do not escape single quotes for bytea column. As such, the built INSERT SQL can be invalid because single quotes can appear in values. For example, 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

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

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]
  Powered by Linux