exam questions

Exam 1z0-809 All Questions

View all questions & answers for the 1z0-809 exam

Exam 1z0-809 topic 1 question 154 discussion

Actual exam question from Oracle's 1z0-809
Question #: 154
Topic #: 1
[All 1z0-809 Questions]

Given the structure of the Student table:
Student (id INTEGER, name VARCHAR)
Given the records from the STUDENT table:

Given the code fragment:

Assume that:
✑ The required database driver is configured in the classpath.
✑ The appropriate database is accessible with the dbURL, userName, and passWord exists.
What is the result?

  • A. The program prints Status: true and two records are deleted from the Student table.
  • B. The program prints Status: false and two records are deleted from the Student table.
  • C. A SQLException is thrown at runtime.
  • D. The program prints Status: false but the records from the Student table are not deleted.
Show Suggested Answer Hide Answer
Suggested Answer: B 🗳️

Comments

Chosen Answer:
This is a voting comment (?). It is better to Upvote an existing comment if you don't have anything to add.
Switch to a voting comment New
steefaand
5 months, 4 weeks ago
Selected Answer: B
B is correct since execute returns true for SELECT queries and false for others.
upvoted 1 times
...
WilsonKKerll
2 years, 4 months ago
Answer is B.
upvoted 1 times
...
AVB22
2 years, 9 months ago
execute boolean execute(String sql) throws SQLException Returns:true if the first result is a ResultSetobject; false if it is an update count or there are no results
upvoted 1 times
...
Svetleto13
3 years, 2 months ago
B is correct.
upvoted 1 times
...
Community vote distribution
A (35%)
C (25%)
B (20%)
Other
Most Voted
A voting comment increases the vote count for the chosen answer by one.

Upvoting a comment with a selected answer will also increase the vote count towards that answer by one. So if you see a comment that you already agree with, you can upvote it instead of posting a new comment.

SaveCancel
Loading ...
exam
Someone Bought Contributor Access for:
SY0-701
London, 1 minute ago