code: public int findColumn(final String columnLabel) throws SQLException {
          if (this.queryResult.getResultSetType() == ResultSetType.SELECT) {
              try {
                  return ((SelectQueryResult) queryResult).getColumnId(columnLabel) + 1;
              } catch (NoSuchColumnException e) {
                  throw SQLExceptionMapper.getSQLException("No such column: " + columnLabel, e);
              }
          }
          throw SQLExceptionMapper.getSQLException("Cannot get column id of update result sets");
      }
docs: Maps the given <code>ResultSet</code> column label to its <code>ResultSet</code> column index.
  
  @param columnLabel the label for the column specified with the SQL AS clause.  If the SQL AS clause was not
  specified, then the label is the name of the column
  @return the column index of the given column name
  @throws java.sql.SQLException if the <code>ResultSet</code> object does not contain a column labeled
  <code>columnLabel</code>, a database access error occurs or this method is called
  on a closed result set