code: func (us *UnionScanExec) getOneRow(ctx context.Context) ([]types.Datum, error) {
  	for {
  		snapshotRow, err := us.getSnapshotRow(ctx)
  		if err != nil {
  			return nil, err
  		}
  		addedRow := us.getAddedRow()
  		var row []types.Datum
  		var isSnapshotRow bool
  		if addedRow == nil {
  			row = snapshotRow
  			isSnapshotRow = true
  		} else if snapshotRow == nil {
  			row = addedRow
  		} else {
  			isSnapshotRow, err = us.shouldPickFirstRow(snapshotRow, addedRow)
  			if err != nil {
  				return nil, err
  			}
  			if isSnapshotRow {
  				row = snapshotRow
  			} else {
  				row = addedRow
  			}
  		}
  		if row == nil {
  			return nil, nil
  		}
  
  		if isSnapshotRow {
  			us.cursor4SnapshotRows++
  		} else {
  			us.cursor4AddRows++
  		}
  		return row, nil
  	}
  }
docs: // getOneRow gets one result row from dirty table or child.