Skip to main content

read_columns_from_projection

Function read_columns_from_projection 

Source
pub fn read_columns_from_projection(
    projection: ProjectionInput,
    metadata: &RegionMetadataRef,
) -> Result<ReadColumns>
Expand description

Build ReadColumns from [ProjectionInput].

Note: If projection.projection is empty, this function still reads the time index column so the scan can preserve row counts for empty-output queries such as SELECT COUNT(*).

Order:

  • This function keeps the first-seen order from projection.projection (duplicate indices are skipped).
  • Keeping a stable order makes ReadColumns comparisons deterministic (Eq/Hash) and avoids cache-key instability in upper layers.