ERROR: insufficient data left in message

From: Robert Wimmer <seppwimmer(at)hotmail(dot)com>
To: <pgsql-jdbc(at)postgresql(dot)org>
Subject: ERROR: insufficient data left in message
Date: 2008-04-28 22:51:20
Message-ID: BAY139-W17522EA1404D646B6A38B3D0DE0@phx.gbl
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-jdbc

I always get the error "insufficient data left in message" running a prepared statement via jdbc executeQuery

the java statement

"ResultSet rs = this.updateStatement.executeQuery();"

results in the following error message :
java.sql.SQLException: ERROR: insufficient data left in message.

the insert statement is

INSERT INTO person.person (id, lastName, readOnly, birthDay, firstName) VALUES(DEFAULT,?,?,?,?) RETURNING id

the server LOG file says the following

2008-04-29 00:15:24 CEST ERROR: insufficient data left in message
2008-04-29
00:15:24 CEST STATEMENT: INSERT INTO person.person (id, lastName,
readOnly, birthDay, firstName) VALUES(DEFAULT,$1,$2,$3,$4) RETURNING id
2008-04-29 00:15:24 CEST LOG: could not receive data from client: Connection reset by peer

i
also tried this statement via the psql command line and it worked.
there is also a similar update statement that works perfect

###
ResultSet rs = this.updateStatement.executeQuery();
// and the record is updated
// log
2008-04-29 00:34:45 CEST LOG: could not receive data from client: Connection reset by peer
2008-04-29 00:34:45 CEST LOG: unexpected EOF on client connection
###

i am using Postgres 8.2 and jdbc 3.0 for 8.2 (i also tried it with jdbc 4.0 but it did not work either).

i have no idea what the problem is - can someone help me ?

regards sepp

_________________________________________________________________
Der Messenger plaudert gerne - egal ob zu zweit oder mit allen gemeinsam. Willkommen in der Familie! Den neuen Windows Live Messenger jetzt herunterladen!
http://get.live.com/messenger/overview/

Responses

Browse pgsql-jdbc by date

  From Date Subject
Next Message Oliver Jowett 2008-04-29 04:37:03 Re: ERROR: insufficient data left in message
Previous Message John R Pierce 2008-04-28 16:22:44 Re: Database Connection pool