On 12/20/2012 11:17 AM, achyutkumar88@gmail.com wrote:
> The following bug has been logged on the website:
>
> Bug reference: 7762
> Logged by: Achyut kumar Dwivedi
> Email address: achyutkumar88@gmail.com
> PostgreSQL version: 9.0.0
> Operating system: Windows
> Description:
>
> Hello Dear
>
> I am one of the user of postgres open source DB and i am getting the problem
> from the reading the binary data of bytea field on 9.0 onwards version with
> the windows OS only but it is working fine on 8.4 version on same platform.
>
> Problem is this produce the content size just double of original size of
> content with the reading code on java language.
>
> get bytes("bytefieldname");
>
> if the content size in 1002 byte, it will get the data of size 2005 byte.
>
> So plz can u help me what can i do to reduce this problem.
the default output format for bytea was changed in 9.0 (see the release
notes http://www.postgresql.org/docs/9.0/static/release-9-0.html in the
"Migration to version 9.0" section) which might be causing the effect
you are seeing.
I have no idea about the jdbc/java stuff but either you need to move to
a more recent version of the jdc driver your you need to change the
bytea_output guc to 'escape'.
Stefan