problem with serialization - Mailing list pgsql-jdbc

From candreol
Subject problem with serialization
Date
Msg-id 3B5ED5EC.F532ABE0@consol.de
Whole thread Raw
Responses RE: problem with serialization
List pgsql-jdbc
Hi! I am new here.

I did a small test to try object serialization with the
org.postgresql.util.Serialize class.

I get the following exception  when I try to use the at
org.postgresql.util.Serialize.create Method. :

java.lang.NullPointerException
at org.postgresql.jdbc2.ResultSet.getString(ResultSet.java:148)
  at org.postgresql.util.Serialize.create(Serialize.java:241)
at org.postgresql.util.Serialize.create(Serialize.java:220)


I looked at  create in Serialization.java and saw that
the exception occurs at getString although I have no table corresponding
to the class I want to serialize.
    if(!rs.next()){
       //   String lolo=rs.getString(1);}
     }

Although the resultset is empty (because the table is absent) , why
getString  has been run ?

Can you help me  ?

   Chris


pgsql-jdbc by date:

Previous
From: Joseph Shraibman
Date:
Subject: Re: Help! Driver cannot be loaded.
Next
From: "Dave Cramer"
Date:
Subject: RE: problem with serialization