Skip to content

Commit

Permalink
Merge pull request #173 from izikorgad/master
Browse files Browse the repository at this point in the history
Fix Java RuntimeException for failed queries.
  • Loading branch information
CraZySacX committed Apr 16, 2018
2 parents f684fb1 + 7d48538 commit 6295a62
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion lib/resultset.js
Original file line number Diff line number Diff line change
Expand Up @@ -104,7 +104,13 @@ ResultSet.prototype.toObjectIter = function (callback) {
types: _.map(colsmetadata, 'type'),
rows: {
next: function () {
var nextRow = self._rs.nextSync();
var nextRow;
try {
nextRow = self._rs.nextSync(); // this row can lead to Java RuntimeException - sould be cathced.
}
catch (error) {
callback(error);
}
if (!nextRow) {
return {
done: true
Expand Down

0 comments on commit 6295a62

Please sign in to comment.