pub struct QueryBuilder { /* private fields */ }Expand description
Query builder for raw SQL with type-safe parameter binding.
Implementations§
Source§impl QueryBuilder
impl QueryBuilder
Sourcepub fn new(sql: impl Into<String>) -> QueryBuilder
pub fn new(sql: impl Into<String>) -> QueryBuilder
Create a new query builder with the given SQL.
Sourcepub fn bind(self, value: impl Into<Value>) -> QueryBuilder
pub fn bind(self, value: impl Into<Value>) -> QueryBuilder
Bind a parameter value.
Sourcepub fn bind_all(self, values: impl IntoIterator<Item = Value>) -> QueryBuilder
pub fn bind_all(self, values: impl IntoIterator<Item = Value>) -> QueryBuilder
Bind multiple parameter values.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for QueryBuilder
impl RefUnwindSafe for QueryBuilder
impl Send for QueryBuilder
impl Sync for QueryBuilder
impl Unpin for QueryBuilder
impl UnsafeUnpin for QueryBuilder
impl UnwindSafe for QueryBuilder
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, _span: NoopSpan) -> Self
fn instrument(self, _span: NoopSpan) -> Self
Instruments this future with a span (no-op when disabled).
Source§fn in_current_span(self) -> Self
fn in_current_span(self) -> Self
Instruments this future with the current span (no-op when disabled).