After reading the explanation, I still don't get what caused the exception at runtime. To the best of my knowledge, the rs will return 2 rows. The rs.next() moves the cursor to the 1st row, then rs.getString(1) will get the id at the 1st row in 1st column.
Anybody can help? Thank you in advance!
About Question enthuware.ocpjp.v8.2.1910 :
Moderator: admin
-
- Posts: 3
- Joined: Mon Jun 12, 2017 1:13 pm
- Contact:
-
- Site Admin
- Posts: 10053
- Joined: Fri Sep 10, 2010 9:26 pm
- Contact:
Re: About Question enthuware.ocpjp.v8.2.1910 :
There will be no exception at runtime. That is why option 1 (It will print two ids from the table.) is the correct option.
HTH,
Paul.
HTH,
Paul.
If you like our products and services, please help us by posting your review here.
Who is online
Users browsing this forum: No registered users and 48 guests