Skip to main content

Module vector

Module vector 

Source
Expand description

The vector itself.

spec/07-execution.md section 7.1 calls this the widest interface in the system, says every operator depends on it, and says changing it after twenty operators exist is expensive. So it is written before the first operator rather than after the fifth.

A vector is a type, a length of at most VECTOR_SIZE, a physical form, a validity representation and some data. The four forms are the ones in spec/04-architecture.md section 4.3: flat, constant, sequence and dictionary. Encoded, the fifth, is the M3 work and it arrives with the specialization contract rather than before it.

What is not here yet. Buffers are owned. Section 7.1 says a vector borrowed from a buffer managed page carries a pin, and there is no buffer manager until M2, so there is nothing to pin and pretending otherwise would be an interface built against an imaginary caller. Nested types are not stored yet either, for the same reason: a LIST(STRUCT(...)) is offsets plus child column chunks, and child column chunks are storage.

Structs§

Vector
A type, a length, a validity representation and some data.

Enums§

Data
The values of a flat vector, one Rust vector per physical type.
Form
Which physical form a vector is in.

Constants§

VECTOR_SIZE
How many values are in a full vector.