# HG changeset patch # User František Kučera # Date 1595690719 -7200 # Node ID a9d4a8d5c57f0498bc9884fee30fa51a1b0dd379 # Parent 97dbb1015d9868a184a3e328a6821ca9627e2886 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 (?). diff -r 97dbb1015d98 -r a9d4a8d5c57f java/sql-dk/src/main/java/info/globalcode/sql/dk/DatabaseConnection.java --- 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);