• 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

an illigal cursor status.

 
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hello

Can anyone give me al clue?
I want to execute a the following query on an MS access DB via jdbc-odbc bridge
Class.forName(DRIVER);
Connection con = DriverManager.getConnection(URL);
Statement st = con.createStatement();
con.setAutoCommit(true);
ResultSet rs = st.executeQuery("SELECT MAX(persId) FROM Persoon");
System.out.println(rs.getInt("persId"));

I would like it to return the max value of the int persId.
But i get an 'Illigal cursor status' (SQLException id=43).
I'm working with tomcat 5.0 and eclipse.

I hope someone knows what i'm doing..............wrong.

thanks

Levien.
 
Sheriff
Posts: 7023
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Welcome to JavaRanch, Levien de Reu!

I'm moving this to the JDBC forum...
[ November 28, 2004: Message edited by: Dirk Schreckmann ]
 
I love a woman who dresses in stainless steel ... and carries tiny ads:
a bit of art, as a gift, that will fit in a stocking
https://gardener-gift.com
reply
    Bookmark Topic Watch Topic
  • New Topic