public static ResultSet getAsResultSet(
Result result, int numberBlocksPerCall)
throws WebRowSetResultSetParseException
{
DataSourceDataValueIterator dsdvi =
new DataSourceDataValueIterator(result.getDataSource());
dsdvi.setNumBlocksPerCall(numberBlocksPerCall);
Reader reader = new DataValueReader(dsdvi, 1);
WebRowSetToResultSet converter = new WebRowSetToResultSet(reader);
converter.setResultSetType(ResultSet.TYPE_FORWARD_ONLY);
return converter.getResultSet();
}