× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.



Earlier wrote:
. . .
As soon as their own example code,
http://www.tutorialspoint.com/jdbc/updating-result-sets.htm
gets to
rs.updateDouble( "age", newAge );
it throws
com.mysql.jdbc.NotUpdatable: Result Set not updatable (referenced
table has no primary keys). . . .

Well, it took me a bunch of digging, but I finally found out how to add a primary key to a MySQL database in SequelPro, so I could try the example again, and sure enough, it worked.

Too bad the tutorial didn't mention that little detail (or if it did, it buried it rather deeply). At least the webmaster apologized for the irate automated message issued by their board.

Interesting: at least in MySQL, JDBC won't let you have an updatable result set if the table doesn't have a primary key.

Once again, this whole business of database engines that don't even have a concept of RRNs is more than a little bit annoying.

I wonder what I will find when I finish the tutorial (and possibly others, like the one Mr. Gibbs recommended to me on the Java list) on MySQL, and go through it all again on DB2/400 . . . . ?

--
JHHL

As an Amazon Associate we earn from qualifying purchases.

This thread ...

Replies:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.