本文整理了Java中java.sql.ResultSet.getFetchSize
方法的一些代码示例,展示了ResultSet.getFetchSize
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。ResultSet.getFetchSize
方法的具体详情如下:
包路径:java.sql.ResultSet
类名称:ResultSet
方法名:getFetchSize
[英]Gets the fetch size (in number of rows) for this ResultSet.
[中]获取此结果集的获取大小(以行数为单位)。
代码示例来源:origin: codingapi/tx-lcn
@Override
public int getFetchSize() throws SQLException {
return delegate.getFetchSize();
}
代码示例来源:origin: querydsl/querydsl
@Override
public int getFetchSize() throws SQLException {
return rs.getFetchSize();
}
代码示例来源:origin: apache/incubator-shardingsphere
@Override
public final int getFetchSize() throws SQLException {
return resultSets.get(0).getFetchSize();
}
代码示例来源:origin: alibaba/druid
@Override
public int getFetchSize() throws SQLException {
try {
return rs.getFetchSize();
} catch (Throwable t) {
throw checkException(t);
}
}
代码示例来源:origin: alibaba/druid
@Override
public int resultSet_getFetchSize(ResultSetProxy rs) throws SQLException {
if (this.pos < filterSize) {
return nextFilter()
.resultSet_getFetchSize(this, rs);
}
return rs.getResultSetRaw()
.getFetchSize();
}
代码示例来源:origin: p6spy/p6spy
@Override
public int getFetchSize() throws SQLException {
return delegate.getFetchSize();
}
代码示例来源:origin: Meituan-Dianping/Zebra
@Override
public int getFetchSize() throws SQLException {
return innerResultSet.getFetchSize();
}
代码示例来源:origin: Meituan-Dianping/Zebra
@Override
public int getFetchSize() throws SQLException {
return innerResultSet.getFetchSize();
}
代码示例来源:origin: apache/phoenix
@Override
public int getFetchSize() throws SQLException {
return rs.getFetchSize();
}
代码示例来源:origin: com.alibaba/druid
@Override
public int getFetchSize() throws SQLException {
try {
return rs.getFetchSize();
} catch (Throwable t) {
throw checkException(t);
}
}
代码示例来源:origin: palantir/atlasdb
private void advanceRow() {
if (Thread.currentThread().isInterrupted()) {
throw new PalantirInterruptedException("Interrupted while iterating through results."); //$NON-NLS-1$
}
try{
numRowsFetchedSinceLastChange++;
if (numRowsFetchedSinceLastChange >= results.getFetchSize()){
results.setFetchSize(Math.min(results.getFetchSize() * 2, maxFetchSize));
numRowsFetchedSinceLastChange = 0;
}
} catch (SQLException e){
sqlExceptionlog.info("Caught SQLException", e);
log.error("Caught SQLException", e); //$NON-NLS-1$
Throwables.rewrapAndThrowUncheckedException(e);
}
try {
hasNext = results.next();
}
catch(SQLException sqlex) {
log.error("Caught SQLException", sqlex); //$NON-NLS-1$
Throwables.rewrapAndThrowUncheckedException(sqlex);
}
hasReadRow = false;
}
代码示例来源:origin: com.alibaba/druid
@Override
public int resultSet_getFetchSize(ResultSetProxy rs) throws SQLException {
if (this.pos < filterSize) {
return nextFilter()
.resultSet_getFetchSize(this, rs);
}
return rs.getResultSetRaw()
.getFetchSize();
}
代码示例来源:origin: apache/phoenix
assertTrue(rs.getFetchSize() > 0);
rs.close();
代码示例来源:origin: apache/phoenix
assertTrue(rs.getFetchSize() > 0);
rs.close();
代码示例来源:origin: apache/activemq-artemis
@Override
public int getFetchSize() throws SQLException {
int x = resultSet.getFetchSize();
logger.logf(level, "%s.getFetchSize() = %s", resultSetID, x);
return x;
}
代码示例来源:origin: ontop/ontop
@Override
public int getFetchSize() throws OntopConnectionException {
try {
return rs.getFetchSize();
} catch (Exception e) {
throw new OntopConnectionException(e.getMessage());
}
}
代码示例来源:origin: org.apache.commons/commons-dbcp2
@Override
public int getFetchSize() throws SQLException {
try {
return resultSet.getFetchSize();
} catch (final SQLException e) {
handleException(e);
return 0;
}
}
代码示例来源:origin: it.unibz.inf.ontop/ontop-system-sql-core
@Override
public int getFetchSize() throws OntopConnectionException {
try {
return rs.getFetchSize();
} catch (Exception e) {
throw new OntopConnectionException(e.getMessage());
}
}
代码示例来源:origin: org.jboss.jbossas/jboss-as-connector
public int getFetchSize() throws SQLException
{
checkState();
try
{
return resultSet.getFetchSize();
}
catch (Throwable t)
{
throw checkException(t);
}
}
代码示例来源:origin: io.agroal/agroal-pool
@Override
public int getFetchSize() throws SQLException {
try {
return wrappedResultSet.getFetchSize();
} catch ( SQLException se ) {
statement.getConnectionWrapper().getHandler().setFlushOnly( se );
throw se;
}
}
内容来源于网络,如有侵权,请联系作者删除!