Class JoinResultSet

    • Field Detail

      • rowsSeenLeft

        public int rowsSeenLeft
      • rowsSeenRight

        public int rowsSeenRight
      • rowsReturned

        public int rowsReturned
      • restrictionTime

        public long restrictionTime
      • isRightOpen

        protected boolean isRightOpen
      • leftRow

        protected ExecRow leftRow
      • rightRow

        protected ExecRow rightRow
      • mergedRow

        protected ExecRow mergedRow
      • leftNumCols

        protected int leftNumCols
      • rightNumCols

        protected int rightNumCols
      • oneRowRightSide

        public boolean oneRowRightSide
      • notExistsRightSide

        public boolean notExistsRightSide
      • userSuppliedOptimizerOverrides

        java.lang.String userSuppliedOptimizerOverrides
    • Constructor Detail

      • JoinResultSet

        JoinResultSet​(NoPutResultSet leftResultSet,
                      int leftNumCols,
                      NoPutResultSet rightResultSet,
                      int rightNumCols,
                      Activation activation,
                      GeneratedMethod restriction,
                      int resultSetNumber,
                      boolean oneRowRightSide,
                      boolean notExistsRightSide,
                      double optimizerEstimatedRowCount,
                      double optimizerEstimatedCost,
                      java.lang.String userSuppliedOptimizerOverrides)
    • Method Detail

      • clearScanState

        void 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()

      • openCore

        public void openCore()
                      throws StandardException
        open a scan on the join. For a join, this means: o Open the left ResultSet o Do a getNextRow() on the left ResultSet to establish a position and get "parameter values" for the right ResultSet. NOTE: It is possible for the getNextRow() to return null, in which case there is no need to open the RightResultSet. We must remember this condition. o If the getNextRow() on the left ResultSet succeeded, then open() the right ResultSet. scan parameters are evaluated at each open, so there is probably some way of altering their values...
        Specified by:
        openCore in interface NoPutResultSet
        Throws:
        StandardException - Thrown on error
      • close

        public void close()
                   throws StandardException
        If the result set has been opened, close the open scan. WARNING does not track close time, since it is expected to be called directly by its subclasses, and we don't want to skew the times
        Specified by:
        close in interface ResultSet
        Overrides:
        close in class NoPutResultSetImpl
        Throws:
        StandardException - thrown on error
      • getRowLocation

        public RowLocation getRowLocation()
        A join is combining rows from two sources, so it has no single row location to return; just return a null.
        Specified by:
        getRowLocation in interface CursorResultSet
        Returns:
        the row location of the current cursor row.
        See Also:
        CursorResultSet
      • getCurrentRow

        public ExecRow getCurrentRow()
        A join is combining rows from two sources, so it should never be used in a positioned update or delete.
        Specified by:
        getCurrentRow in interface CursorResultSet
        Returns:
        a null value.
        See Also:
        CursorResultSet