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

Function crm_schema

nodedb-strict/src/decode.rs:480–495  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

478 use crate::encode::TupleEncoder;
479
480 fn crm_schema() -> StrictSchema {
481 StrictSchema::new(vec![
482 ColumnDef::required("id", ColumnType::Int64).with_primary_key(),
483 ColumnDef::required("name", ColumnType::String),
484 ColumnDef::nullable("email", ColumnType::String),
485 ColumnDef::required(
486 "balance",
487 ColumnType::Decimal {
488 precision: 18,
489 scale: 4,
490 },
491 ),
492 ColumnDef::nullable("active", ColumnType::Bool),
493 ])
494 .unwrap()
495 }
496
497 fn encode_crm_row(values: &[Value]) -> Vec<u8> {
498 let schema = crm_schema();

Callers 10

encode_crm_rowFunction · 0.70
roundtrip_all_fieldsFunction · 0.70
roundtrip_with_nullsFunction · 0.70
extract_by_nameFunction · 0.70
null_bitmap_checkFunction · 0.70
column_out_of_rangeFunction · 0.70
schema_version_readFunction · 0.70

Calls

no outgoing calls

Tested by 9

roundtrip_all_fieldsFunction · 0.56
roundtrip_with_nullsFunction · 0.56
extract_by_nameFunction · 0.56
null_bitmap_checkFunction · 0.56
column_out_of_rangeFunction · 0.56
schema_version_readFunction · 0.56