This week's giveaway is in the EJB and other Java EE Technologies forum.
We're giving away four copies of EJB 3 in Action and have Debu Panda, Reza Rahman, Ryan Cuprak, and Michael Remijan on-line!
See this thread for details.
The moose likes JDBC and the fly likes ResultSet--Can not able to get the value of the column Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of EJB 3 in Action this week in the EJB and other Java EE Technologies forum!
JavaRanch » Java Forums » Databases » JDBC
Bookmark "ResultSet--Can not able to get the value of the column" Watch "ResultSet--Can not able to get the value of the column" New topic
Author

ResultSet--Can not able to get the value of the column

abhi thewall
Greenhorn

Joined: Mar 08, 2008
Posts: 1
Hi All,

I am working on a swing project.I have created the statement and executed query.
Got the result set object.Now fron result set object I am trying to get the value of the column amount using rs.getInt("Amount");
Its showing Invalid cursor state.

I can get the meta data from the resultset object and from where if i am trying to find the column number or column name its giving correctly.

But not able to call any other method on resultset object except rs.next,rs.first etc.

Here is the code:--

 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: ResultSet--Can not able to get the value of the column
 
Similar Threads
Scrollable Result Sets
Retrieving data from cachedRowSet
Calling Oracle Function that returns %ROWTYPE
got error: Invalid column index
Couldn't retreive a String from the result set