code: func copySelectedInnerRows(innerColOffset, outerColOffset int, src *Chunk, selected []bool, dst *Chunk) int {
  	oldLen := dst.columns[innerColOffset].length
  	var srcCols []*column
  	if innerColOffset == 0 {
  		srcCols = src.columns[:outerColOffset]
  	} else {
  		srcCols = src.columns[innerColOffset:]
  	}
  	for j, srcCol := range srcCols {
  		dstCol := dst.columns[innerColOffset+j]
  		if srcCol.isFixed() {
  			for i := 0; i < len(selected); i++ {
  				if !selected[i] {
  					continue
  				}
  				dstCol.appendNullBitmap(!srcCol.isNull(i))
  				dstCol.length++
  
  				elemLen := len(srcCol.elemBuf)
  				offset := i * elemLen
  				dstCol.data = append(dstCol.data, srcCol.data[offset:offset+elemLen]...)
  			}
  		} else {
  			for i := 0; i < len(selected); i++ {
  				if !selected[i] {
  					continue
  				}
  				dstCol.appendNullBitmap(!srcCol.isNull(i))
  				dstCol.length++
  
  				start, end := srcCol.offsets[i], srcCol.offsets[i+1]
  				dstCol.data = append(dstCol.data, srcCol.data[start:end]...)
  				dstCol.offsets = append(dstCol.offsets, int32(len(dstCol.data)))
  			}
  		}
  	}
  	return dst.columns[innerColOffset].length - oldLen
  }
docs: // copySelectedInnerRows copies the selected inner rows from the source Chunk
  // to the destination Chunk.
  // return the number of rows which is selected.