Time Travel¶
The Lance Flink connector supports reading historical versions of a dataset via
time-travel options, resolved uniformly through LanceOpener.
Options¶
| Option | Type | Description |
|---|---|---|
read.version |
LONG | Read the given dataset version (highest precedence) |
read.as-of-timestamp |
STRING | Read as of an ISO-8601 timestamp; resolves to the newest version whose creation time is ≤ the timestamp |
When both are set, read.version takes precedence.
Examples¶
-- Read a specific version
SELECT * FROM lance_table /*+ OPTIONS('read.version' = '3') */;
-- Read as of a timestamp (resolves to the newest version <= the timestamp)
SELECT * FROM lance_table /*+ OPTIONS('read.as-of-timestamp' = '2026-07-01T00:00:00Z') */;
Declaratively on the table DDL:
CREATE TABLE lance_table (
id BIGINT,
content STRING
) WITH (
'connector' = 'lance',
'path' = '/data/vectors',
'read.version' = '3'
);
Semantics¶
read.versionopens exactly that version.read.as-of-timestampaccepts any string parseable byInstant.parse,OffsetDateTime.parse, orZonedDateTime.parse; a bareyyyy-MM-ddTHH:mm:ssis assumed UTC.- A timestamp predating the oldest version raises a clear error.
- Time travel is read-only:
write.mode = overwritereplaces the dataset with a new version, so earlier versions stay reachable until Lance garbage-collects them.