Fix missing records on small datasets using the batchput udaf