pg.ddx.io  pgsql-sql@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Craig Ringer <craig@postnewspapers.com.au>
To: Jasmin Dizdarevic <jasmin.dizdarevic@gmail.com>
Cc: pgsql-sql@postgresql.org
Subject: Re: Which version of PostgreSQL should I use.
Date: Wed, 25 May 2011 09:56:33 +0800
Message-ID: <4DDC61D1.70009@postnewspapers.com.au> (raw)
In-Reply-To: <BANLkTimMyHpZp0F0AX5RDFqTHRA_tChfrA@mail.gmail.com>
References: <1614341677-1306219359-cardhu_decombobulator_blackberry.rim.net-1916432553-@b26.c13.bise7.blackberry>
	<4DDB54A6.9000006@postnewspapers.com.au>
	<BANLkTimMyHpZp0F0AX5RDFqTHRA_tChfrA@mail.gmail.com>

On 24/05/11 18:58, Jasmin Dizdarevic wrote:
> Alright, I've misunderstood this issue. Do you have to escape bytea
> columns during export or import? And how you would do this?

Some database drivers and some apps don't understand the new hex output
format for bytea columns.

IIRC, the format change should ONLY affect how bytea values are sent
from the server to the client using the standard text-based postgresql
protocol.

When using apps/drivers that aren't ready for the hex format yet, you must

  SET bytea_output TO 'escape';

This can be done at the postgresql.conf level (globally), by ALTERing
the database the app uses, by ALTERing the user ID the app connects
with, or by modifying the app so it knows to issue an explicit SET
before doing any work with a connection.

AFAIK there is no impact on dump/load, though you *could* see problems
if you used an application's own dump/load feature rather than pg_dump
and the app wasn't ready for the new bytea format.

--
Craig Ringer



view thread (8+ messages)

Message-ID: <4DDC61D1.70009@postnewspapers.com.au>
Permalink:  ../4DDC61D1.70009@postnewspapers.com.au/
Also on:    postgresql.org/message-id/4DDC61D1.70009@postnewspapers.com.au

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: pgsql-sql@postgresql.org
  Cc: craig@postnewspapers.com.au, jasmin.dizdarevic@gmail.com
  Subject: Re: Which version of PostgreSQL should I use.
  In-Reply-To: <4DDC61D1.70009@postnewspapers.com.au>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox