pg.ddx.io  pgsql-admin@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: James Im <im-james@hotmail.com>
To: pgsql-jdbc@postgresql.org
Subject: invalid byte sequence for encoding "UTF8": 0x00
Date: Tue, 20 Feb 2007 10:48:43 +0000
Message-ID: <BAY7-F17FFE0E324AB3B642C547E96890@phx.gbl> (raw)

Hi,

I've got another problem. I sometimes get the following SQLException
when doing an insert:

ERROR: invalid byte sequence for encoding "UTF8": 0x00
Exception: org.postgresql.util.PSQLException
org.postgresql.core.v3.QueryExecutorImpl.receiveErrorResponse(QueryExecutorImpl.java:1525)
org.postgresql.core.v3.QueryExecutorImpl.processResults(QueryExecutorImpl.java:1309)
org.postgresql.core.v3.QueryExecutorImpl.execute(QueryExecutorImpl.java:188)
org.postgresql.jdbc2.AbstractJdbc2Statement.execute(AbstractJdbc2Statement.java:452)
org.postgresql.jdbc2.AbstractJdbc2Statement.executeWithFlags(AbstractJdbc2Statement.java:354)
org.postgresql.jdbc2.AbstractJdbc2Statement.executeUpdate(AbstractJdbc2Statement.java:308)

By the way, the insert is done with a PreparedStatement and I use only
setLong(), setString(), setTimestamp() and setInt().


I don't understand it very well. It is obviously an encoding exception
but I don't know why it happens and what I could do avoid it.

Any idea?

_________________________________________________________________
Opret en personlig blog og del dine billeder på MSN Spaces:  
http://spaces.msn.com/




view thread (29+ messages)  latest in thread

Message-ID: <BAY7-F17FFE0E324AB3B642C547E96890@phx.gbl>
Permalink:  ../BAY7-F17FFE0E324AB3B642C547E96890@phx.gbl/
Also on:    postgresql.org/message-id/BAY7-F17FFE0E324AB3B642C547E96890@phx.gbl

 · 

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-admin@postgresql.org
  Cc: im-james@hotmail.com, pgsql-jdbc@postgresql.org
  Subject: Re: invalid byte sequence for encoding "UTF8": 0x00
  In-Reply-To: <BAY7-F17FFE0E324AB3B642C547E96890@phx.gbl>

* 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