• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

PSQLException: Operation requires a scrollable ResultSet, but this ResultSet is FORWARD ONLY

 
Greenhorn
Posts: 8
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi guys!

Thanks to be so helpful all the times I need of help.. you literary saved my ass many many times!
Well.. let's go to the matter...
In the production environment we are going to use Tomcat 6.0.24. I installed it properly, but when I test my application, in some part I get this exception, that I do not get in the old production tomcat:

org.postgresql.util.PSQLException: Operation requires a scrollable ResultSet, but this ResultSet is FORWARD_ONLY.
at org.postgresql.jdbc2.AbstractJdbc2ResultSet.checkScrollable(AbstractJdbc2ResultSet.java:207)
at org.postgresql.jdbc2.AbstractJdbc2ResultSet.first(AbstractJdbc2ResultSet.java:292)
at org.apache.tomcat.dbcp.dbcp.DelegatingResultSet.first(DelegatingResultSet.java:326)

As driver for the DB I am using postgresql-8.6.603.jdbc3.jar and pg74.216.jdbc3.jar both placed under the CATALINA_HOME/lib.

Can you tell me what is wrong?Am I missing some other libraries? The fact is that the same code is working in the old production environment and in my local host with tomcat6.0.18..

HEEEEEEEEEEEEEEEEEELP!!!

Cheers!
Mario
 
Saloon Keeper
Posts: 27764
196
Android Eclipse IDE Tomcat Server Redhat Java Linux
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
You usually see that message when using an ORM such as HIbernate where you want to move forwards and backwards but the ResultSet wasn't opened in a 2-way scroll mode and therefore can only move forwards.

Since this message is coming from the connection pooler, I think maybe it's attempting to do some cleanup on a released connection and it's doing it in a questionable way.

As a quick hack, you might try substituting the dbcp.jar file from your older version of Tomcat and see if the problem goes away,
 
reply
    Bookmark Topic Watch Topic
  • New Topic