[−][src]Struct postgres_querybuilder::UpdateBuilder
Implementations
impl UpdateBuilder
[src]
pub fn new(from: &str) -> Self
[src]
Create a new update builder for a given table
Examples
use postgres_querybuilder::UpdateBuilder; use postgres_querybuilder::prelude::{QueryBuilder, QueryBuilderWithSet, QueryBuilderWithWhere}; let user_password = "password".to_string(); let mut builder = UpdateBuilder::new("users"); builder.set("username", "rick".to_string()); builder.where_eq("id", 42); assert_eq!(builder.get_query(), "UPDATE users SET username = $1 WHERE id = $2");
Trait Implementations
impl QueryBuilder for UpdateBuilder
[src]
fn add_param<T: 'static + ToSql + Sync + Clone>(&mut self, value: T) -> usize
[src]
fn get_query(&self) -> String
[src]
fn get_ref_params(self) -> Vec<&'static (dyn ToSql + Sync)>
[src]
impl QueryBuilderWithQueries for UpdateBuilder
[src]
fn with_query(&mut self, name: &str, query: &str) -> &mut Self
[src]
impl QueryBuilderWithSet for UpdateBuilder
[src]
fn set<T: 'static + ToSql + Sync + Clone>(
&mut self,
field: &str,
value: T
) -> &mut Self
[src]
&mut self,
field: &str,
value: T
) -> &mut Self
fn set_computed(&mut self, field: &str, value: &str) -> &mut Self
[src]
impl QueryBuilderWithWhere for UpdateBuilder
[src]
Auto Trait Implementations
impl !RefUnwindSafe for UpdateBuilder
impl !Send for UpdateBuilder
impl Sync for UpdateBuilder
impl Unpin for UpdateBuilder
impl !UnwindSafe for UpdateBuilder
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> Same<T> for T
type Output = T
Should always be Self
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<V, T> VZip<V> for T where
V: MultiLane<T>,
V: MultiLane<T>,