firstContainer.zeroVectors();
if (spilledBatches > 0) {
VectorContainer c = getBatch();
Iterator<VectorWrapper<?>> wrapperIterator = c.iterator();
for (VectorWrapper w : firstContainer) {
TransferPair pair = wrapperIterator.next().getValueVector().makeTransferPair(w.getValueVector());
pair.transfer();
}
firstContainer.setRecordCount(c.getRecordCount());
c.zeroVectors();
} else {
batchPointer = -1;
pointer = -1;
firstContainer.zeroVectors();
secondContainer.zeroVectors();
}
if (spilledBatches > 0) {
VectorContainer c = getBatch();
Iterator<VectorWrapper<?>> wrapperIterator = c.iterator();
for (VectorWrapper w : secondContainer) {
TransferPair pair = wrapperIterator.next().getValueVector().makeTransferPair(w.getValueVector());
pair.transfer();
}
secondContainer.setRecordCount(c.getRecordCount());
c.zeroVectors();
} else {
secondContainer.zeroVectors();