Skip to main content

record_batch_to_rows

Function record_batch_to_rows 

Source
pub fn record_batch_to_rows(
    batch: &RecordBatch,
    schema: &TableSchema,
) -> Result<Vec<(InternalKey, Row)>>
Expand description

Convert an Arrow RecordBatch (from a Parquet read) back into (InternalKey, Row) pairs.

Column lookup is by name, not position, so this function works uniformly against:

  • L0 batches (with _merutable_value blob present) — fast path: decode each Row from postcard bytes; the typed columns are ignored.
  • L1+ batches (typed columns only) — materialize each Row field by field from the per-column Arrow arrays.
  • Projected batches that include only a subset of columns, as long as _merutable_ikey is present.