private int countBufferedRows() {
    int count = 0;
    for (int i = 0; i < currentBufferedBatchCount; i++) {
      count += bufferedBatches.get(i).size;
    }
    return count;
  }
Returns the values of ordering columns from a given batch and given row in an Object[].
@param vectorizedRowBatch
@param rowIndexInBatch
@return
ql/src/java/org/apache/hadoop/hive/ql/exec/vector/ptf/VectorPTFGroupBatches.java