Affects Version/s: None
Fix Version/s: None
According to the oracle documentation
For a prepared statement batch, it is not possible to know the number of rows affected in the database by each individual statement in the batch. Therefore, all array elements have a value of -2. According to the JDBC 2.0 specification, a value of -2 indicates that the operation was successful but the number of rows affected is unknown.
As documented update-values returns (-2) which means that the (if (zero?)) check in update-or-insert-values will never return true.
Oracle does provide the number of rows updated via an the method getUpdateCount on instances of Statement.
The following change fixes this problem for oracle users, but I am not sure how it will affect other drivers.