/** * Buffer logical tiles got from executing child executors * This will also initialize a new join row set that belongs * to the new result tile */ void AbstractJoinExecutor::BufferRightTile(LogicalTile *right_tile) { PL_ASSERT(join_type_ != JoinType::INVALID); right_result_tiles_.emplace_back(right_tile); switch (join_type_) { case JoinType::RIGHT: case JoinType::OUTER: UpdateRightJoinRowSets(); break; default: break; } }
/** * Buffer logical tiles got from executing child executors * This will also initialize a new join row set that belongs * to the new result tile */ void AbstractJoinExecutor::BufferRightTile(LogicalTile *right_tile) { assert(join_type_ != JOIN_TYPE_INVALID); right_result_tiles_.emplace_back(right_tile); switch (join_type_) { case JOIN_TYPE_RIGHT: case JOIN_TYPE_OUTER: UpdateRightJoinRowSets(); break; default: break; } }
/** * Update join row sets depending on types of join. * When new result tile is buffered, matching status of the * rows in the new tile should be tracked. * This is called by BufferTile routines, as join row sets * should be updated when new result tile is buffered */ void AbstractJoinExecutor::UpdateJoinRowSets() { PL_ASSERT(join_type_ != JoinType::INVALID); switch (join_type_) { case JoinType::LEFT: UpdateLeftJoinRowSets(); break; case JoinType::RIGHT: UpdateRightJoinRowSets(); break; case JoinType::OUTER: UpdateFullJoinRowSets(); break; default: break; } }
/** * Update join row sets depending on types of join. * When new result tile is buffered, matching status of the * rows in the new tile should be tracked. * This is called by BufferTile routines, as join row sets * should be updated when new result tile is buffered */ void AbstractJoinExecutor::UpdateJoinRowSets() { assert(join_type_ != JOIN_TYPE_INVALID); switch (join_type_) { case JOIN_TYPE_LEFT: UpdateLeftJoinRowSets(); break; case JOIN_TYPE_RIGHT: UpdateRightJoinRowSets(); break; case JOIN_TYPE_OUTER: UpdateFullJoinRowSets(); break; default: break; } }
/** * Update the row set with all rows from the last tile from both child */ void AbstractJoinExecutor::UpdateFullJoinRowSets() { UpdateLeftJoinRowSets(); UpdateRightJoinRowSets(); }