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

Method execute_sql

nodedb-client/src/native/connection/mod.rs:229–240  ·  view source on GitHub ↗

Execute a SQL query and return the result.

(&mut self, sql: &str)

Source from the content-addressed store, hash-verified

227
228 /// Execute a SQL query and return the result.
229 pub async fn execute_sql(&mut self, sql: &str) -> NodeDbResult<QueryResult> {
230 let resp = self
231 .send(
232 OpCode::Sql,
233 TextFields {
234 sql: Some(sql.to_string()),
235 ..Default::default()
236 },
237 )
238 .await?;
239 response_to_query_result(resp)
240 }
241
242 /// Execute a SQL query with bound parameters and return the result.
243 ///

Calls 3

response_to_query_resultFunction · 0.85
to_stringMethod · 0.80
sendMethod · 0.45