| java.lang.Object org.apache.derby.impl.sql.execute.BasicNoPutResultSetImpl org.apache.derby.impl.sql.execute.NoPutResultSetImpl org.apache.derby.impl.sql.execute.TableScanResultSet
All known Subclasses: org.apache.derby.impl.sql.execute.BulkTableScanResultSet,
TableScanResultSet | class TableScanResultSet extends NoPutResultSetImpl implements CursorResultSet,Cloneable(Code) | | Takes a table and a table filter and returns
the table's rows satisfying the filter as a result set.
There are several things we could do during object
construction that are done in the open & next calls, to
improve performance.
author: ames |
Constructor Summary | |
| TableScanResultSet(long conglomId, StaticCompiledOpenConglomInfo scoci, Activation activation, GeneratedMethod resultRowAllocator, int resultSetNumber, GeneratedMethod startKeyGetter, int startSearchOperator, GeneratedMethod stopKeyGetter, int stopSearchOperator, boolean sameStartStopPosition, Qualifier[][] qualifiers, String tableName, String userSuppliedOptimizerOverrides, String indexName, boolean isConstraint, boolean forUpdate, int colRefItem, int indexColItem, int lockMode, boolean tableLocked, int isolationLevel, int rowsPerRead, boolean oneRowScan, double optimizerEstimatedRowCount, double optimizerEstimatedCost) |
coarserLock | public boolean coarserLock(Code) | | |
compareToLastKey | protected boolean compareToLastKey(Code) | | |
conglomId | protected long conglomId(Code) | | |
currentRowPrescanned | protected boolean currentRowPrescanned(Code) | | |
firstScan | protected boolean firstScan(Code) | | |
forUpdate | public boolean forUpdate(Code) | | |
indexCols | protected int[] indexCols(Code) | | |
isConstraint | public boolean isConstraint(Code) | | |
isKeyed | protected boolean isKeyed(Code) | | |
isolationLevel | public int isolationLevel(Code) | | |
lockMode | public int lockMode(Code) | | |
oneRowScan | public boolean oneRowScan(Code) | | |
rowsPerRead | public int rowsPerRead(Code) | | |
rowsThisScan | protected long rowsThisScan(Code) | | |
runTimeStatisticsOn | protected boolean runTimeStatisticsOn(Code) | | |
scanControllerOpened | protected boolean scanControllerOpened(Code) | | |
skipFutureRowHolder | protected boolean skipFutureRowHolder(Code) | | |
sourceDrained | protected boolean sourceDrained(Code) | | |
startSearchOperator | protected int startSearchOperator(Code) | | |
stopSearchOperator | protected int stopSearchOperator(Code) | | |
userSuppliedOptimizerOverrides | public String userSuppliedOptimizerOverrides(Code) | | |
TableScanResultSet | TableScanResultSet(long conglomId, StaticCompiledOpenConglomInfo scoci, Activation activation, GeneratedMethod resultRowAllocator, int resultSetNumber, GeneratedMethod startKeyGetter, int startSearchOperator, GeneratedMethod stopKeyGetter, int stopSearchOperator, boolean sameStartStopPosition, Qualifier[][] qualifiers, String tableName, String userSuppliedOptimizerOverrides, String indexName, boolean isConstraint, boolean forUpdate, int colRefItem, int indexColItem, int lockMode, boolean tableLocked, int isolationLevel, int rowsPerRead, boolean oneRowScan, double optimizerEstimatedRowCount, double optimizerEstimatedCost) throws StandardException(Code) | | |
canGetInstantaneousLocks | protected boolean canGetInstantaneousLocks()(Code) | | Can we get instantaneous locks when getting share row
locks at READ COMMITTED.
|
clone | public Object clone()(Code) | | Shallow clone this result set. Used in trigger reference.
beetle 4373.
|
getCurrentRow | public ExecRow getCurrentRow() throws StandardException(Code) | | This result set has its row from the last fetch done.
If the cursor is closed, the row has been deleted, or
no longer qualifies (for forward only result sets) a
null is returned.
See Also: CursorResultSet the last row returned; exception: StandardException - thrown on failure. |
getRowLocation | public RowLocation getRowLocation() throws StandardException(Code) | | This result set has its row location from
the last fetch done. If the cursor is closed,
or the row has been deleted a null is returned.
See Also: CursorResultSet the row location of the current cursor row. exception: StandardException - thrown on failure to get row location |
getTimeSpent | public long getTimeSpent(int type)(Code) | | Return the total amount of time spent in this ResultSet
Parameters: type - CURRENT_RESULTSET_ONLY - time spent only in this ResultSetENTIRE_RESULTSET_TREE - time spent in this ResultSet and below. long The total amount of time spent (in milliseconds). |
isForUpdate | public boolean isForUpdate()(Code) | | Is this ResultSet or it's source result set for update
Whether or not the result set is for update. |
openCore | public void openCore() throws StandardException(Code) | | open a scan on the table. scan parameters are evaluated
at each open, so there is probably some way of altering
their values...
exception: StandardException - thrown on failure to open |
printStartPosition | public String printStartPosition()(Code) | | Print an array of Qualifiers to the trace stream.
|
reopenCore | public void reopenCore() throws StandardException(Code) | | Reopen a table scan. Here we take advantage
of the reopenScan() interface on scanController
for optimimal performance on joins where we are
an inner table.
exception: StandardException - thrown on failure to open |
setRowCountIfPossible | final protected void setRowCountIfPossible(long rowsThisScan) throws StandardException(Code) | | Update the number of rows in the scan controller.
NOTE: It would be more efficient to only update the
scan controller if the optimizer's estimated number of
rows were wrong by more than some threshold (like 10%).
This would require a little more work than I have the
time for now, however, as the row estimate that is given
to this result set is the total number of rows for all
scans, not the number of rows per scan.
Parameters: rowsThisScan - The number of rows to update the scanController to exception: StandardException - Thrown on error |
|
|