nerdexam
Oracle

1Z0-809 · Question #270

1Z0-809 Question #270: Real Exam Question with Answer & Explanation

Sign in or unlock 1Z0-809 to reveal the answer and full explanation for question #270. The question stem and answer options stay visible for context.

Question

Given the EMPLOYEE table:
EMP_IDEMP_NAME
100Tom
101Mary
102Peter
103Robin
Given the code fragment: try (Connection con = DriverManager.getConnection (dbURL, user, passwd)); { Statement stmt = con.createStatement (ResultSet.TYPE_SCROLL_SENSITIVE, ResultSet.CONCUR_UPDATABLE); ResultSet rs = stmt.executeQuery ("SELECT * FROM employees"); rs.absolute (3); // Line1 rs.moveToInsertRow(); rs.updateInt(1, 104); rs.updateString(2, "Michael"); rs.insertRow(); rs.moveToCurrentRow(); System.out.println ("Employee Id: " + rs.getInt(1) + ", Employee Name: " + rs.getString(2)); } Assuming the database supports scrolling and updating, what is the result?

Options

  • AThe program throws a runtime exception at Line 1.
  • BA compilation error occurs.
  • CA new record is inserted and Employee id: 102, Employee Name: Peter is displayed.
  • DA new record is inserted and Employee id: 104, Employee Name: Michael is displayed.

Unlock 1Z0-809 to see the answer

You've previewed enough free 1Z0-809 questions. Unlock 1Z0-809 for full answers, explanations, the timed quiz mode, progress tracking, and the master PDF. Question stem and options stay visible so you can still see what's on the exam.

Full 1Z0-809 Practice