Search in sources :

Example 1 with ForwardOnlyResultSetTable

use of org.dbunit.database.ForwardOnlyResultSetTable in project sharding-jdbc by shardingjdbc.

the class SQLAssertHelper method createTable.

private CachedResultSetTable createTable(final String tableName, final PreparedStatement preparedStatement, final IDatabaseConnection connection) throws SQLException, DataSetException {
    preparedStatement.execute();
    ResultSet rs = preparedStatement.getResultSet();
    ITableMetaData metaData = new ResultSetTableMetaData(tableName, rs, connection, false);
    ForwardOnlyResultSetTable table = new ForwardOnlyResultSetTable(metaData, rs);
    return new CachedResultSetTable(table);
}
Also used : ForwardOnlyResultSetTable(org.dbunit.database.ForwardOnlyResultSetTable) ResultSetTableMetaData(org.dbunit.database.ResultSetTableMetaData) CachedResultSetTable(org.dbunit.database.CachedResultSetTable) ResultSet(java.sql.ResultSet) ITableMetaData(org.dbunit.dataset.ITableMetaData)

Aggregations

ResultSet (java.sql.ResultSet)1 CachedResultSetTable (org.dbunit.database.CachedResultSetTable)1 ForwardOnlyResultSetTable (org.dbunit.database.ForwardOnlyResultSetTable)1 ResultSetTableMetaData (org.dbunit.database.ResultSetTableMetaData)1 ITableMetaData (org.dbunit.dataset.ITableMetaData)1