@lancedb/lancedb • Docs
@lancedb/lancedb / MaterializedView
Class: MaterializedView¶
A handle on a materialized view: its table plus its definition.
Obtained from Connection#createMaterializedView or Connection#openMaterializedView. The view is a normal table -- queries, indexes and search all apply through MaterializedView#table -- whose contents are maintained by MaterializedView#refresh.
Constructors¶
new MaterializedView()¶
Parameters¶
- table:
Table
Returns¶
Accessors¶
name¶
Returns¶
string
Methods¶
definition()¶
The query that defines the view.
Returns¶
Promise<MaterializedViewDefinition>
refresh()¶
Recompute the view from its source.
Every refresh rebuilds the complete view. For local views,
sourceVersion refreshes to that source version instead of the latest;
remote SQL refreshes do not support source-version pinning.
Parameters¶
-
options?
-
options.sourceVersion?:
number
Returns¶
Promise<RefreshMaterializedViewResult>
table()¶
The view, as the table it is.