This week's book giveaway is in the Servlets forum.
We're giving away four copies of Murach's Java Servlets and JSP and have Joel Murach on-line!
See this thread for details.
The moose likes JDBC and the fly likes java.sql.SQLException: Result set is in an invalid state. May be before the first row or after the Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Murach's Java Servlets and JSP this week in the Servlets forum!
JavaRanch » Java Forums » Databases » JDBC
Bookmark "java.sql.SQLException: Result set is in an invalid state. May be before the first row or after the " Watch "java.sql.SQLException: Result set is in an invalid state. May be before the first row or after the " New topic
Author

java.sql.SQLException: Result set is in an invalid state. May be before the first row or after the

Kalai Selvi
Ranch Hand

Joined: Jan 08, 2007
Posts: 45
I am using JNDI Datasource (running in weblogic8.1) to connect to database. I have inserted 2 rows in the table. Below is the code. I am able to get the resultset. But, I get
"java.sql.SQLException: Result set is in an invalid state. May be before the first row or after the last row". I can understand this is because of not positioning the pointer at the correct place in resultset. I am trying different possibilities. Please let me know what the problem could be?

 
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
 
subject: java.sql.SQLException: Result set is in an invalid state. May be before the first row or after the
 
Similar Threads
Getting DataSource object through JNDI in WebSphere 6.1
Getting DataSource object through JNDI in WebSphere 6.1
WAS 6.1 JDBC problem
Getting DataSource object through JNDI in WebSphere 6.1
Oracle10gDataStoreHelper