@lancedb/lancedb • Docs
@lancedb/lancedb / QueryExecutionOptions
Interface: QueryExecutionOptions¶
Options that control the behavior of a particular query execution
Properties¶
blobMode?¶
How to return blob v2 columns. Applies to toArrow() and toArray().
"descriptions"(default): each blob is a descriptor. Read the bytes with Table.fetchBlobs or Table.fetchBlobFiles."bytes": each blob column, including blobs nested in structs, holds the bytes asLargeBinary. The query also reads_rowidto fetch them, and leaves it out of the result unless QueryBase.withRowId was called. All the bytes are held in memory.
Selecting a parent struct or directly aliasing a blob or struct also returns bytes. Blobs inside lists keep their descriptors. Arbitrary projection expressions are not materialized as bytes.
The rows and the bytes come from the same table version. If the table changes while the query runs, the query runs again, up to three times.
Example¶
const rows = await table
.query()
.select(["id", "image"])
.toArray({ blobMode: "bytes" });
const image: Uint8Array | null = rows[0].image;
maxBatchLength?¶
The maximum number of rows to return in a single batch
Batches may have fewer rows if the underlying data is stored in smaller chunks.
timeoutMs?¶
Timeout for query execution in milliseconds