Como resolver isto?

rs= meu resultset

if ({
//Se não vazia faz algo
rs.previous(); //aqui dá o erro abaixo
while ( {
} //end do while
else {
//SQL vazia

org.firebirdsql.jdbc.FBDriverNotCapableException: Result set is TYPE_FORWARD_ONLY
at org.firebirdsql.jdbc.FBCachedFetcher.previous(
at org.firebirdsql.jdbc.FBResultSet.previous(
at Bco.doPost(
at javax.servlet.http.HttpServlet.service(
at javax.servlet.http.HttpServlet.service(
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(
at org.apache.catalina.core.ApplicationFilterChain.doFilter(
at org.apache.catalina.core.StandardWrapperValve.invoke(
at org.apache.catalina.core.StandardContextValve.invoke(
at org.apache.catalina.core.StandardHostValve.invoke(
at org.apache.catalina.valves.ErrorReportValve.invoke(
at org.apache.catalina.core.StandardEngineValve.invoke(
at org.apache.catalina.connector.CoyoteAdapter.service(
at org.apache.coyote.http11.Http11Processor.process(
at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.processConnection(
at org.apache.tomcat.util.threads.ThreadPool$

Tem como dizer ao driver, ou a conexão para ela gerar resultsets bi-direcionais ou o Resultset é um tipo apenas forward (o resultset é o problema)?


Isto deve responder minha própria pergunta.

[quote]A default ResultSet object is not updatable and has a cursor that moves forward only. Thus, you
can iterate through it only once and only from the first row to the last row. It is possible to produce
ResultSet objects that are scrollable and/or updatable. The following code fragment, in which con is
a valid Connection object, illustrates how to make a result set that is scrollable and insensitive to
updates by others, and that is updatable. See ResultSet fields for other options.

   Statement stmt = con.createStatement(
   ResultSet rs = stmt.executeQuery("SELECT a, b FROM TABLE2");
   // rs will be scrollable, will not show changes made by others,
   // and will be updatable[/quote]

Outra solução melhor?

É, essa é a solução a primeira vista.