Re: bytea insert difference between 8.3 and 9.x - Mailing list pgsql-general

From Merlin Moncure
Subject Re: bytea insert difference between 8.3 and 9.x
Date
Msg-id CAHyXU0yezy8ke7Szxoa-h1drXGQNDEWWrmQBvdat8-hBMy7uDQ@mail.gmail.com
Whole thread Raw
In response to Re: bytea insert difference between 8.3 and 9.x  (Gregg Jaskiewicz <gryzman@gmail.com>)
Responses Re: bytea insert difference between 8.3 and 9.x
List pgsql-general
On Mon, Sep 26, 2011 at 8:50 AM, Gregg Jaskiewicz <gryzman@gmail.com> wrote:
> Thanks Merin.
>
> It does, and that's probably what I'll do. Your solution isn't great
> either, because it requires extra function to be run on the postgresql
> side. Me no likeey that ;)

If you are sending a bytea as encoded text, you have to call a
decoding function on the server side no matter what -- it's implicitly
done for you some cases though.  the decode() route is x-version and
guarantees hex method of transfer, not the old escaped method which is
stupid and slow.

The only way to not send encoded text is via binary switch in the
protocol...not sure if libpqxx supports this method of execution.

merlin

pgsql-general by date:

Previous
From: Merlin Moncure
Date:
Subject: Re: bytea insert difference between 8.3 and 9.x
Next
From: DUPREZ Cédric
Date:
Subject: Problem with pg_upgrade from 9.0 to 9.1 under Ubuntu x64