public synchronized void setFetchSize(int rows) throws SQLExceptionParameters: 
rows - the number of rows to fetch 
Throws: SQLException 
if a database access error occurs, or the condition 0 <= rows <= this.getMaxRows() is not satisfieduse as: resultSet.setFetchSize(100);

解决方案 »

  1.   

    设置结果集每次从数据库中读取的数据的条数。例如结果集中有1000条纪录,FetchSize为100,则每次只取100条纪录到客户端。
      

  2.   

    to:yanghhelen(yanghui) 比如我要是跳转到 301 条记录,那么“客户端”(实际上是应用服务器)得到应该是那些记录呢? 301 - 400? 还是别的?在数据分页显示中是不是可以考虑设置这个参数?有人用下面的方法进行数据分页显示,是不是有必要?SELECT * FROM ( SELECT ROWNUM r, mytable.* FROM mytable ) WHERE r >= fromRowNum AND r <= toRowNum