File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes JDBC and Relational Databases and the fly likes problem with the resultset Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Databases » JDBC and Relational Databases
Bookmark "problem with the resultset" Watch "problem with the resultset" New topic

problem with the resultset

kiran kumar

Joined: Feb 07, 2005
Posts: 29
Hi, see the bellow code . i am not able to execute updateString() method.

In the above statement iam getting some error like
readable resultset can not be updatable
i am using oracle 9i

please reply to the above problem

[edited to disable smilies and add code tags]
[ February 07, 2005: Message edited by: Jeanne Boyarsky ]
Jeanne Boyarsky
author & internet detective

Joined: May 26, 2003
Posts: 33125

Welcome to JavaRanch!

I'm just curious what you are trying to do here. Is there something significant about the fifth row? It tends to be dangerous to rely on the data returning in a specific order.

The problem might be due to using absolute(). Try the following and see if it still fails:

[This time I forgot to disable smilies!]
[ February 07, 2005: Message edited by: Jeanne Boyarsky ]

[OCA 8 book] [Blog] [JavaRanch FAQ] [How To Ask Questions The Smart Way] [Book Promos]
Other Certs: SCEA Part 1, Part 2 & 3, Core Spring 3, TOGAF part 1 and part 2
Avi Abrami
Ranch Hand

Joined: Oct 11, 2000
Posts: 1141

If you haven't already done so, please refer to the section entitled ResultSet Limitations in Oracle's JDBC User's Guide and Reference. Not all queries can produce updatable "ResultSet"s. As stated in the Oracle documentation, the Oracle JDBC driver will silently convert updatabale "ResultSet"s to read-only "ResultSet"s for such queries.

In your case, it looks like "select * from EMP" cannot produce an updatable "ResultSet".

By the way, the Oracle documentation also states that there may be problems in using "select *", and recommends using explicit column lists instead.

Perhaps you shoud [re?] read the Oracle documentation?

Good Luck,
I agree. Here's the link:
subject: problem with the resultset
It's not a secret anymore!