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

Method eval_with_old

nodedb-query/src/expr/eval.rs:70–76  ·  view source on GitHub ↗

Evaluate with access to both NEW and OLD documents, used by TRANSITION CHECK predicates. `Column(name)` resolves against `new_doc`; `OldColumn(name)` resolves against `old_doc`.

(&self, new_doc: &Value, old_doc: &Value)

Source from the content-addressed store, hash-verified

68 /// TRANSITION CHECK predicates. `Column(name)` resolves against
69 /// `new_doc`; `OldColumn(name)` resolves against `old_doc`.
70 pub fn eval_with_old(&self, new_doc: &Value, old_doc: &Value) -> Value {
71 self.eval_scope(&RowScope {
72 new_doc,
73 old_doc: Some(old_doc),
74 excluded_doc: None,
75 })
76 }
77
78 /// Evaluate with access to the incoming `EXCLUDED.*` row, used by
79 /// `INSERT ... ON CONFLICT DO UPDATE`. `Column(name)` resolves

Callers 1

Calls 1

eval_scopeMethod · 0.80

Tested by

no test coverage detected