fn drain_data_buffer_to_record_batches(
schema: SchemaRef,
buffer: &mut DataBuffer,
pk_weights: Option<&[u16]>,
dedup: bool,
replace_pk_index: bool,
) -> Result<RecordBatch>Expand description
Converts DataBuffer to record batches, with rows sorted according to pk_weights.
dedup: whether to true to remove the duplicated rows inside DataBuffer.
replace_pk_index: whether to replace the pk_index values with corresponding pk weight.