diff --git a/WHATSNEW b/WHATSNEW index f765ad80c..d91ac4ada 100644 --- a/WHATSNEW +++ b/WHATSNEW @@ -82,6 +82,10 @@ Fixed bugs: * The .NET compilation tasks failed if filenames given as references contained spaces. Bugzilla Report 27170. +* SQL task would try access result sets of statements that didn't + return any, causing problems with Informix IDS 9.2 and IBM DB2 8.1 + FixPak 6 (or later). Bugzilla Reports 27162 and 29954. + Other changes: -------------- @@ -513,8 +517,6 @@ Fixed bugs: * macrodef @@ escaping was broken. Bugzilla Report 27069. -* SQL task did not work with Informix IDS 9.2. Bugzilla Report 27162. - * MacroDef did not allow attributes named 'description'. Bugzilla Report 27175. * Throw build exception if name attribute missing from patternset#NameEntry. diff --git a/src/main/org/apache/tools/ant/taskdefs/SQLExec.java b/src/main/org/apache/tools/ant/taskdefs/SQLExec.java index 9d6728494..30bd9f520 100644 --- a/src/main/org/apache/tools/ant/taskdefs/SQLExec.java +++ b/src/main/org/apache/tools/ant/taskdefs/SQLExec.java @@ -590,9 +590,10 @@ public class SQLExec extends JDBCTask { * @param rs the resultset to print information about * @param out the place to print results * @throws SQLException on SQL problems. - * @since Ant 1.7 + * @since Ant 1.6.3 */ - protected void printResults(ResultSet rs, PrintStream out) throws SQLException { + protected void printResults(ResultSet rs, PrintStream out) + throws SQLException { if (rs != null) { log("Processing new result set.", Project.MSG_VERBOSE); ResultSetMetaData md = rs.getMetaData();