MCPcopy Create free account
hub / github.com/NodeDB-Lab/nodedb / plan_scan

Method plan_scan

nodedb-sql/src/engine_rules/document_schemaless.rs:34–62  ·  view source on GitHub ↗
(&self, p: ScanParams)

Source from the content-addressed store, hash-verified

32 }
33
34 fn plan_scan(&self, p: ScanParams) -> Result<SqlPlan> {
35 if p.temporal.is_temporal() && !p.bitemporal {
36 return Err(SqlError::Unsupported {
37 detail: format!(
38 "FOR SYSTEM_TIME / FOR VALID_TIME requires a bitemporal \
39 collection; '{}' was not created WITH bitemporal = true",
40 p.collection
41 ),
42 });
43 }
44 if let Some(plan) =
45 crate::engine_rules::try_document_index_lookup(&p, EngineType::DocumentSchemaless)
46 {
47 return Ok(plan);
48 }
49 Ok(SqlPlan::Scan {
50 collection: p.collection,
51 alias: p.alias,
52 engine: EngineType::DocumentSchemaless,
53 filters: p.filters,
54 projection: p.projection,
55 sort_keys: p.sort_keys,
56 limit: p.limit,
57 offset: p.offset,
58 distinct: p.distinct,
59 window_functions: p.window_functions,
60 temporal: p.temporal,
61 })
62 }
63
64 fn plan_point_get(&self, p: PointGetParams) -> Result<SqlPlan> {
65 Ok(SqlPlan::PointGet {

Callers

nothing calls this directly

Calls 2

is_temporalMethod · 0.80

Tested by

no test coverage detected