Hi!
First, there's a very small spelling error in the second and third answers, I think "querries" should be "queries", but that doesn't matter much.
I answerd this incorrectly because I assumed it'd throw an SQLException trying to update through the ResultSet at since it wasn't created with any int resultSetConcurrency, especially lacking the ResultSet.CONCUR_UPDATABLE.
https://docs.oracle.com/javase/8/docs/a ... ltSet.html mentions at the description in the top:
A default ResultSet object is not updatable and has a cursor that moves forward only.
This is backed by the Java Tutorials at
https://docs.oracle.com/javase/tutorial ... eving.html
There are two concurrency levels:
CONCUR_READ_ONLY: The ResultSet object cannot be updated using the ResultSet interface.
CONCUR_UPDATABLE: The ResultSet object can be updated using the ResultSet interface.
The default ResultSet concurrency is CONCUR_READ_ONLY.
So I wrongly chose the following answers:
It will execute one query on the database.
and
It will throw an exception at //1
So I think my mistake was that in this context, I read "updatable" in the javadoc and tutorial as "being able to executeUpdate() on the resultset" but I should have interpreted it as "refreshable" as in "refreshRow() actually loads the new data". Is that correct?
It's hard for me to get a grip on JDBC when certain rules/ agreements are interpreted differently by different database vendors so trying things out with SQLite might give different results than trying it out with let's say MariaDB. It's all a little bit abstract without having a setup where I can try things out while knowing that quirks are not caused by vendors or certain versions. Any tips on how I could improve that are very welcome but I understand it very well if you can't provide that.
Thank you for your time!