Are ResultSets updateable?

  1. O (a) Yes, but only if you call the method openCursor() on the ResultSet, and if the driver and

  2. O (b) Yes, but only if you indicate a concurrency strategy when executing the statement, and

  3. O (c) Yes, but only if the ResultSet is an object of class UpdateableResultSet, and if the driver

  4. O (d) No, ResultSets are never updateable. You must explicitly execute DML statements (i.e.


Correct Option: B
Explanation:

To answer this question, the user needs to have knowledge about ResultSets and their characteristics.

Option A is incorrect because there is no openCursor() method in the ResultSet class.

Option B is partially correct. The ResultSet object is updateable only if you indicate a concurrency strategy when executing the statement, and the driver supports updateable ResultSets.

Option C is incorrect because there is no class called UpdateableResultSet in the Java API.

Option D is incorrect because ResultSets can be updateable, but it depends on the driver, the type of ResultSet, and the concurrency strategy used.

Therefore, the correct answer is:

The Answer is: B

Find more quizzes: