title: JDBC SELECT COUNT(*) returns empty resultset on HSQLDB
body: <p>I would expect to always receive a resultset with one row on a SELECT COUNT, but results.next() always returns false. This is on HSQLDB 2.5.1.
  The code below prints:</p>
  <blockquote>
  <p>number of columns: 1. First column C1 with type INTEGER</p>
  <p>No COUNT results</p>
  </blockquote>
  <pre><code>           statement = connection.createStatement();
              // check if table empty
              statement.executeQuery(&quot;SELECT COUNT(*)  FROM mytable&quot;);
              ResultSet results = statement.getResultSet();
              System.out.println(&quot;number of columns: &quot; + results.getMetaData().getColumnCount() + &quot;. First column &quot; +results.getMetaData().getColumnName(1) + &quot; with type &quot; +results.getMetaData().getColumnTypeName(1) );
              int numberOfRows = 0;
              boolean hasResults = results.next();
              if (hasResults){
                  numberOfRows = results.getInt(1);
                  System.out.println(&quot;Table size &quot; + numberOfRows );
              }else{
                  System.out.println(&quot;No COUNT results&quot; );
              }
              statement.close();
  </code></pre>
  <p>Executing the same SQL statement in my SQL console works fine:</p>
  <div class="s-table-container">
  <table class="s-table">
  <thead>
  <tr>
  <th style="text-align: left;">C1</th>
  </tr>
  </thead>
  <tbody>
  <tr>
  <td style="text-align: left;">104</td>
  </tr>
  </tbody>
  </table>
  </div>
  <p>Other JDBC actions on this database work fine as well.
  Is there something obvious I'm missing?</p>