Trait diesel::query_builder::AsQuery
[−]
[src]
pub trait AsQuery { type SqlType; type Query: Query<SqlType = Self::SqlType>; fn as_query(self) -> Self::Query; }
Types that can be converted into a complete, typed SQL query. This is used
internally to automatically add the right select clause when none is
specified, or to automatically add RETURNING *
in certain contexts
Associated Types
Required Methods
Implementors
impl<T, U, Op> AsQuery for InsertStatement<T, U, Op, NoReturningClause> where
T: Table,
InsertStatement<T, U, Op, ReturningClause<T::AllColumns>>: Query, type SqlType = <Self::Query as Query>::SqlType; type Query = InsertStatement<T, U, Op, ReturningClause<T::AllColumns>>;impl<T, U, V> AsQuery for UpdateStatement<T, U, V, NoReturningClause> where
T: Table,
UpdateStatement<T, U, V, ReturningClause<T::AllColumns>>: Query, type SqlType = <Self::Query as Query>::SqlType; type Query = UpdateStatement<T, U, V, ReturningClause<T::AllColumns>>;impl<T: Query> AsQuery for T type SqlType = Self::SqlType; type Query = Self;