Top Description Fields Constructors Methods
org.apache.derby.impl.sql.execute

pack-priv Class NestedLoopJoinResultSet

extends JoinResultSet
Class Inheritance
Known Direct Subclasses
org.apache.derby.impl.sql.execute.NestedLoopLeftOuterJoinResultSet, org.apache.derby.impl.sql.execute.HashJoinResultSet
Imports
org.apache.derby.shared.common.error.StandardException, org.apache.derby.shared.common.reference.SQLState, org.apache.derby.iapi.services.loader.GeneratedMethod, org.apache.derby.iapi.sql.Activation, org.apache.derby.iapi.sql.execute.ExecRow, .NoPutResultSet, org.apache.derby.iapi.types.DataValueDescriptor

Takes 2 NoPutResultSets and a join filter and returns the join's rows satisfying the filter as a result set.

Field Summary

Modifier and TypeField and Description
private boolean
private ExecRow
Inherited from org.apache.derby.impl.sql.execute.JoinResultSet:
isRightOpenleftNumColsleftResultSetleftRowmergedRownotExistsRightSideoneRowRightSiderestrictionrestrictionTimerightNumColsrightResultSetrightRowrowsReturnedrowsSeenLeftrowsSeenRightuserSuppliedOptimizerOverrides

Constructor Summary

AccessConstructor and Description
pack-priv
NestedLoopJoinResultSet(NoPutResultSet leftResultSet, int leftNumCols, NoPutResultSet rightResultSet, int rightNumCols, Activation activation, GeneratedMethod restriction, int resultSetNumber, boolean oneRowRightSide, boolean notExistsRightSide, double optimizerEstimatedRowCount, double optimizerEstimatedCost, String userSuppliedOptimizerOverrides)

Method Summary

Modifier and TypeMethod and Description
pack-priv void
clearScanState()

Overrides org.apache.derby.impl.sql.execute.JoinResultSet.clearScanState.

Clear any private state that changes during scans.

public void
close()

Overrides org.apache.derby.impl.sql.execute.JoinResultSet.close.

Implements org.apache.derby.iapi.sql.ResultSet.close.

If the result set has been opened, close the open scan.

public ExecRow

Returns:

the next row in the join result
getNextRowCore
()

Implements abstract org.apache.derby.impl.sql.execute.BasicNoPutResultSetImpl.getNextRowCore.

Implements org.apache.derby.iapi.sql.execute.NoPutResultSet.getNextRowCore.

Return the requested values computed from the next row (if any) for which the restriction evaluates to true.

public long

Returns:

long The total amount of time spent (in milliseconds).
getTimeSpent
(int
CURRENT_RESULTSET_ONLY - time spent only in this ResultSet ENTIRE_RESULTSET_TREE - time spent in this ResultSet and below.
type
)

Implements org.apache.derby.iapi.sql.ResultSet.getTimeSpent.

Return the total amount of time spent in this ResultSet

Inherited from org.apache.derby.impl.sql.execute.JoinResultSet:
closeRightfinishgetCurrentRowgetRowLocationopenCoreopenRightreopenCore

Field Detail

returnedRowMatchingRightSideback to summary
private boolean returnedRowMatchingRightSide
rightTemplateback to summary
private ExecRow rightTemplate

Constructor Detail

NestedLoopJoinResultSetback to summary
pack-priv NestedLoopJoinResultSet(NoPutResultSet leftResultSet, int leftNumCols, NoPutResultSet rightResultSet, int rightNumCols, Activation activation, GeneratedMethod restriction, int resultSetNumber, boolean oneRowRightSide, boolean notExistsRightSide, double optimizerEstimatedRowCount, double optimizerEstimatedCost, String userSuppliedOptimizerOverrides)

Method Detail

clearScanStateback to summary
pack-priv void clearScanState()

Overrides org.apache.derby.impl.sql.execute.JoinResultSet.clearScanState.

Clear any private state that changes during scans. This includes things like the last row seen, etc. THis does not include immutable things that are typically set up in the constructor.

This method is called on open()/close() and reopen()

Warning

this should be implemented in every sub class and it should always call super.clearScanState().

closeback to summary
public void close() throws StandardException

Overrides org.apache.derby.impl.sql.execute.JoinResultSet.close.

Implements org.apache.derby.iapi.sql.ResultSet.close.

If the result set has been opened, close the open scan.

Exceptions
StandardException:
thrown on error
getNextRowCoreback to summary
public ExecRow getNextRowCore() throws StandardException

Implements abstract org.apache.derby.impl.sql.execute.BasicNoPutResultSetImpl.getNextRowCore.

Implements org.apache.derby.iapi.sql.execute.NoPutResultSet.getNextRowCore.

Return the requested values computed from the next row (if any) for which the restriction evaluates to true.

restriction parameters are evaluated for each row.

Returns:ExecRow

the next row in the join result

Exceptions
StandardException:
  • Thrown on error
  • ResultSetNotOpen thrown if closed
getTimeSpentback to summary
public long getTimeSpent(int type)

Implements org.apache.derby.iapi.sql.ResultSet.getTimeSpent.

Return the total amount of time spent in this ResultSet

Parameters
type:int

CURRENT_RESULTSET_ONLY - time spent only in this ResultSet ENTIRE_RESULTSET_TREE - time spent in this ResultSet and below.

Returns:long

long The total amount of time spent (in milliseconds).