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

Function bind_multiple_params

nodedb-sql/src/params.rs:136–143  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

134
135 #[test]
136 fn bind_multiple_params() {
137 let result = bind_and_format(
138 "SELECT * FROM users WHERE age > $1 AND name = $2",
139 &[ParamValue::Int64(18), ParamValue::Text("bob".into())],
140 );
141 assert!(result.contains("age > 18"), "got: {result}");
142 assert!(result.contains("name = 'bob'"), "got: {result}");
143 }
144
145 #[test]
146 fn bind_insert_values() {

Callers

nothing calls this directly

Calls 1

bind_and_formatFunction · 0.85

Tested by

no test coverage detected