Execute a statement that doesn't return rows (INSERT/UPDATE/DELETE).
(
&self,
sql: &str,
params: &[&(dyn tokio_postgres::types::ToSql + Sync)],
)
| 96 | |
| 97 | /// Execute a statement that doesn't return rows (INSERT/UPDATE/DELETE). |
| 98 | pub(super) async fn execute_raw( |
| 99 | &self, |
| 100 | sql: &str, |
| 101 | params: &[&(dyn tokio_postgres::types::ToSql + Sync)], |
| 102 | ) -> NodeDbResult<u64> { |
| 103 | let client = self.client.lock().await; |
| 104 | client.execute(sql, params).await.map_err(|e| { |
| 105 | NodeDbError::storage(format!("pgwire execute failed: {}", pg_error_detail(&e))) |
| 106 | }) |
| 107 | } |
| 108 | |
| 109 | /// Execute a parameterless statement via the simple-query protocol |
| 110 | /// (single `Query` message — no `Parse`/`Bind`/`Describe` round-trip). |
no test coverage detected