Problem with fixed length fields. - Mailing list pgsql-jdbc

From Dave Smith
Subject Problem with fixed length fields.
Date
Msg-id 1098532450.2684.3.camel@davehome
Whole thread Raw
Responses Re: Problem with fixed length fields.
List pgsql-jdbc
Platform:
Postgres 7.4.5, lastest JDBC driver from CVS.

Table:
create table t(a char(2),b char(2));
insert into t values ('  ','  ');

Jdbc:

This query finds nothing
PreparedStatement st = db.prepareStatement("select * from t where a=?
and b=?");
st.setString(1,"  ");
st.setString(2,"  ");
ResultSet rs = st.executeQuery();

This query works
rs = db.prepareStatement("select * from t where a='  ' and b='
'").executeQuery();

Why?






pgsql-jdbc by date:

Previous
From: Kris Jurka
Date:
Subject: Re: patch: bring org/postgresql/test/README up to date
Next
From: Kris Jurka
Date:
Subject: Re: Problem with fixed length fields.