improve multiple results support
The specification talks exactly about -1:
> Returns: the current result as an update count;
> -1 if the current result is a ResultSet object or there are no more results
Other negative numbers can theoretically mean something different than „no more results“
e.g. unknown number of updates (?).
--- a/java/sql-dk/src/main/java/info/globalcode/sql/dk/DatabaseConnection.java Fri Dec 20 12:55:01 2019 +0100
+++ b/java/sql-dk/src/main/java/info/globalcode/sql/dk/DatabaseConnection.java Sat Jul 25 17:25:19 2020 +0200
@@ -118,7 +118,7 @@
}
logWarnings(ps);
- while (ps.getMoreResults() || ps.getUpdateCount() > -1) {
+ while (ps.getMoreResults() || ps.getUpdateCount() != -1) {
ResultSet rs = ps.getResultSet();
if (rs == null) {
processUpdateResult(ps, formatter);