posted 6 years ago
Hello,
I am trying to resolve the problem , page 842,
OCA/OCP Java® SE 7
Programmer I & II
Study Guide
And assuming the two queries are valid, what is the result of executing this fragment?
A. Query 1 and Query 2 are rolled back ( no change to the database)
B. Query 1 is executed and Query 2 is rolled back
C. Query 1 is executed, Query 2 is executed, and SQLException
D. SQLException
E. A runtime exception is thrown
The correct answer is C.
When I ran my code I don't see 'SQLException' at the console.
I used Derby DB database.
Thanks a lot!