Skip site navigation (1) Skip section navigation (2)

Re: Result set not positioned properly, perhaps you need to

From: Oliver Jowett <oliver(at)opencloud(dot)com>
To: Manuel Sugawara <masm(at)fciencias(dot)unam(dot)mx>
Cc: pgsql-jdbc(at)postgresql(dot)org
Subject: Re: Result set not positioned properly, perhaps you need to
Date: 2004-11-25 23:17:03
Message-ID: 41A667EF.7010406@opencloud.com (view raw or flat)
Thread:
Lists: pgsql-jdbc
Manuel Sugawara wrote:
> I have a system which have been up for years now and recently when
> switched to pg74.215.jdbc3.jar it started to fail saying:
> 
> org.postgresql.util.PSQLException: Result set not positioned properly, perhaps you need to call next().
>         at org.postgresql.jdbc1.AbstractJdbc1ResultSet.checkResultSet(AbstractJdbc1ResultSet.java:823)
>         at org.postgresql.jdbc1.AbstractJdbc1ResultSet.getString(AbstractJdbc1ResultSet.java:200)
>         at org.postgresql.jdbc1.AbstractJdbc1ResultSet.getString(AbstractJdbc1ResultSet.java:480)
>         at org.apache.commons.dbcp.DelegatingResultSet.getString(DelegatingResultSet.java:155)
>         ....
> 
> The funny thing is that switching back to pg74.214.jdbc3.jar solves
> the problem. Is this a know bug?.

Can you show us the application code that causes this? It may be an 
application bug that was hidden by the old driver's behaviour. Newer 
drivers tend to be more aggressive about checking resultset positioning, 
enforcing spec requirements, etc.

-O

In response to

Responses

pgsql-jdbc by date

Next:From: Éric ParéDate: 2004-11-25 23:39:36
Subject: using index with bigint pkey
Previous:From: Manuel SugawaraDate: 2004-11-25 22:42:51
Subject: Result set not positioned properly, perhaps you need to call next().

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group