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

Method exec

nodedb-test-support/src/pgwire_harness/query.rs:112–118  ·  view source on GitHub ↗

Execute a SQL statement expecting success (no result needed).

(&self, sql: &str)

Source from the content-addressed store, hash-verified

110
111 /// Execute a SQL statement expecting success (no result needed).
112 pub async fn exec(&self, sql: &str) -> Result<(), String> {
113 let client = self.client.as_ref();
114 match client.simple_query(sql).await {
115 Ok(_) => Ok(()),
116 Err(e) => Err(pg_error_detail(&e)),
117 }
118 }
119
120 /// Open a second pgwire connection on the same listener under a different
121 /// username. Returns a client and its background connection task handle.

Calls 2

pg_error_detailFunction · 0.70
as_refMethod · 0.45