From: Oliver Jowett <oliver@opencloud.com>
To: john.lister@kickstone.com
Cc: Craig Ringer <craig@postnewspapers.com.au>
Cc: pgsql-jdbc-owner@postgresql.org
Cc: Kris Jurka <books@ejurka.com>
Cc: user2037@ymail.com
Cc: pgsql-jdbc@postgresql.org
Subject: Re: Strings with null characters produce exceptions when selectedor inserted. Attempts to select messages with null bytes produces "ERROR:insufficient data left in message". And inserting produces "ERROR: invalidbyte sequence for encoding \"UTF8\":
Date: Fri, 05 Jun 2009 01:22:56 +1200
Message-ID: <4A27CAB0.4040605@opencloud.com> (raw)
In-Reply-To: <1176993971-1244116729-cardhu_decombobulator_blackberry.rim.net-143516403-@bxe1101.bisx.produk.on.blackberry>
References: <1176993971-1244116729-cardhu_decombobulator_blackberry.rim.net-143516403-@bxe1101.bisx.produk.on.blackberry>
John Lister wrote:
> Apologies for top post using a blackberry. The binary mode should be able to cope fine as it passes the length before sending the data. Should be straightforward to add strings to patch.
It's not that we can't transfer strings with embedded zero bytes to the
server (we can), it's that the server does not handle the resulting
string. From memory it just truncates the string at that point. So we
disallow it in the driver rather than causing strange effects on the
server side.
So adding support for these strings to the binary patch would actually
be a regression.
-O
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 from your mail client; the link fills in
the headers below: reply via email
Some clients, webmail especially, drop In-Reply-To and References from
a link, and the reply then starts a new thread: use the mbox below.
To: pgsql-jdbc@postgresql.org
Cc: oliver@opencloud.com, john.lister@kickstone.com, craig@postnewspapers.com.au, pgsql-jdbc-owner@postgresql.org, books@ejurka.com, user2037@ymail.com
Subject: Re: Strings with null characters produce exceptions when selectedor inserted. Attempts to select messages with null bytes produces "ERROR:insufficient data left in message". And inserting produces "ERROR: invalidbyte sequence for encoding \"UTF8\":
In-Reply-To: <4A27CAB0.4040605@opencloud.com>
References: <1176993971-1244116729-cardhu_decombobulator_blackberry.rim.net-143516403-@bxe1101.bisx.produk.on.blackberry> <4A27CAB0.4040605@opencloud.com>
* 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