diesel::query_builder

Trait QueryFragment

Source
pub trait QueryFragment<DB: Backend, SP = NotSpecialized> {
    // Required method
    fn walk_ast<'b>(&'b self, pass: AstPass<'_, 'b, DB>) -> QueryResult<()>;

    // Provided methods
    fn to_sql(
        &self,
        out: &mut DB::QueryBuilder,
        backend: &DB,
    ) -> QueryResult<()> { ... }
    fn collect_binds<'b>(
        &'b self,
        out: &mut DB::BindCollector<'b>,
        metadata_lookup: &mut DB::MetadataLookup,
        backend: &'b DB,
    ) -> QueryResult<()> { ... }
    fn is_safe_to_cache_prepared(&self, backend: &DB) -> QueryResult<bool> { ... }
    fn is_noop(&self, backend: &DB) -> QueryResult<bool> { ... }
}
Expand description

An untyped fragment of SQL.

This may be a complete SQL command (such as an update statement without a RETURNING clause), or a subsection (such as our internal types used to represent a WHERE clause). Implementations of ExecuteDsl and LoadQuery will generally require that this trait be implemented.

Required Methods§

Source

fn walk_ast<'b>(&'b self, pass: AstPass<'_, 'b, DB>) -> QueryResult<()>

Walk over this QueryFragment for all passes.

This method is where the actual behavior of an AST node is implemented. This method will contain the behavior required for all possible AST passes. See AstPass for more details.

Provided Methods§

Source

fn to_sql(&self, out: &mut DB::QueryBuilder, backend: &DB) -> QueryResult<()>

Available on crate feature i-implement-a-third-party-backend-and-opt-into-breaking-changes only.

Converts this QueryFragment to its SQL representation.

This method should only be called by implementations of Connection.

Source

fn collect_binds<'b>( &'b self, out: &mut DB::BindCollector<'b>, metadata_lookup: &mut DB::MetadataLookup, backend: &'b DB, ) -> QueryResult<()>

Available on crate feature i-implement-a-third-party-backend-and-opt-into-breaking-changes only.

Serializes all bind parameters in this query.

A bind parameter is a value which is sent separately from the query itself. It is represented in SQL with a placeholder such as ? or $1.

This method should only be called by implementations of Connection.

Source

fn is_safe_to_cache_prepared(&self, backend: &DB) -> QueryResult<bool>

Available on crate feature i-implement-a-third-party-backend-and-opt-into-breaking-changes only.

Is this query safe to store in the prepared statement cache?

In order to keep our prepared statement cache at a reasonable size, we avoid caching any queries which represent a potentially unbounded number of SQL queries. Generally this will only return true for queries for which to_sql will always construct exactly identical SQL.

Some examples of where this method will return false are:

  • SqlLiteral (We don’t know if the SQL was constructed dynamically, so we must assume that it was)
  • In and NotIn (Each value requires a separate bind param placeholder)

This method should only be called by implementations of Connection.

Source

fn is_noop(&self, backend: &DB) -> QueryResult<bool>

Available on crate feature i-implement-a-third-party-backend-and-opt-into-breaking-changes only.

Does walking this AST have any effect?

Trait Implementations§

Source§

impl<DB> QueryId for dyn QueryFragment<DB>

Source§

const HAS_STATIC_QUERY_ID: bool = false

Can the SQL generated by Self be uniquely identified by its type? Read more
Source§

type QueryId = ()

A type which uniquely represents Self in a SQL query. Read more
Source§

fn query_id() -> Option<TypeId>

Returns the type id of Self::QueryId if Self::HAS_STATIC_QUERY_ID. Returns None otherwise. Read more

Implementations on Foreign Types§

Source§

impl<'a, T, DB> QueryFragment<DB> for &'a T
where DB: Backend, T: QueryFragment<DB> + ?Sized,

Source§

fn walk_ast<'b>(&'b self, pass: AstPass<'_, 'b, DB>) -> QueryResult<()>

Source§

impl<DB: Backend> QueryFragment<DB> for ()

Source§

fn walk_ast<'b>(&'b self, _: AstPass<'_, 'b, DB>) -> QueryResult<()>

Source§

impl<T0: QueryFragment<__DB>, T1: QueryFragment<__DB>, T2: QueryFragment<__DB>, T3: QueryFragment<__DB>, T4: QueryFragment<__DB>, T5: QueryFragment<__DB>, T6: QueryFragment<__DB>, T7: QueryFragment<__DB>, T8: QueryFragment<__DB>, T9: QueryFragment<__DB>, T10: QueryFragment<__DB>, T11: QueryFragment<__DB>, T12: QueryFragment<__DB>, T13: QueryFragment<__DB>, T14: QueryFragment<__DB>, T15: QueryFragment<__DB>, T16: QueryFragment<__DB>, T17: QueryFragment<__DB>, T18: QueryFragment<__DB>, T19: QueryFragment<__DB>, T20: QueryFragment<__DB>, T21: QueryFragment<__DB>, T22: QueryFragment<__DB>, T23: QueryFragment<__DB>, T24: QueryFragment<__DB>, T25: QueryFragment<__DB>, T26: QueryFragment<__DB>, T27: QueryFragment<__DB>, T28: QueryFragment<__DB>, T29: QueryFragment<__DB>, T30: QueryFragment<__DB>, T31: QueryFragment<__DB>, __DB: Backend> QueryFragment<__DB> for (T0, T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12, T13, T14, T15, T16, T17, T18, T19, T20, T21, T22, T23, T24, T25, T26, T27, T28, T29, T30, T31)

Source§

fn walk_ast<'b>(&'b self, out: AstPass<'_, 'b, __DB>) -> QueryResult<()>

Source§

impl<T0: QueryFragment<__DB>, T1: QueryFragment<__DB>, T2: QueryFragment<__DB>, T3: QueryFragment<__DB>, T4: QueryFragment<__DB>, T5: QueryFragment<__DB>, T6: QueryFragment<__DB>, T7: QueryFragment<__DB>, T8: QueryFragment<__DB>, T9: QueryFragment<__DB>, T10: QueryFragment<__DB>, T11: QueryFragment<__DB>, T12: QueryFragment<__DB>, T13: QueryFragment<__DB>, T14: QueryFragment<__DB>, T15: QueryFragment<__DB>, T16: QueryFragment<__DB>, T17: QueryFragment<__DB>, T18: QueryFragment<__DB>, T19: QueryFragment<__DB>, T20: QueryFragment<__DB>, T21: QueryFragment<__DB>, T22: QueryFragment<__DB>, T23: QueryFragment<__DB>, T24: QueryFragment<__DB>, T25: QueryFragment<__DB>, T26: QueryFragment<__DB>, T27: QueryFragment<__DB>, T28: QueryFragment<__DB>, T29: QueryFragment<__DB>, T30: QueryFragment<__DB>, __DB: Backend> QueryFragment<__DB> for (T0, T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12, T13, T14, T15, T16, T17, T18, T19, T20, T21, T22, T23, T24, T25, T26, T27, T28, T29, T30)

Source§

fn walk_ast<'b>(&'b self, out: AstPass<'_, 'b, __DB>) -> QueryResult<()>

Source§

impl<T0: QueryFragment<__DB>, T1: QueryFragment<__DB>, T2: QueryFragment<__DB>, T3: QueryFragment<__DB>, T4: QueryFragment<__DB>, T5: QueryFragment<__DB>, T6: QueryFragment<__DB>, T7: QueryFragment<__DB>, T8: QueryFragment<__DB>, T9: QueryFragment<__DB>, T10: QueryFragment<__DB>, T11: QueryFragment<__DB>, T12: QueryFragment<__DB>, T13: QueryFragment<__DB>, T14: QueryFragment<__DB>, T15: QueryFragment<__DB>, T16: QueryFragment<__DB>, T17: QueryFragment<__DB>, T18: QueryFragment<__DB>, T19: QueryFragment<__DB>, T20: QueryFragment<__DB>, T21: QueryFragment<__DB>, T22: QueryFragment<__DB>, T23: QueryFragment<__DB>, T24: QueryFragment<__DB>, T25: QueryFragment<__DB>, T26: QueryFragment<__DB>, T27: QueryFragment<__DB>, T28: QueryFragment<__DB>, T29: QueryFragment<__DB>, __DB: Backend> QueryFragment<__DB> for (T0, T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12, T13, T14, T15, T16, T17, T18, T19, T20, T21, T22, T23, T24, T25, T26, T27, T28, T29)

Source§

fn walk_ast<'b>(&'b self, out: AstPass<'_, 'b, __DB>) -> QueryResult<()>

Source§

impl<T0: QueryFragment<__DB>, T1: QueryFragment<__DB>, T2: QueryFragment<__DB>, T3: QueryFragment<__DB>, T4: QueryFragment<__DB>, T5: QueryFragment<__DB>, T6: QueryFragment<__DB>, T7: QueryFragment<__DB>, T8: QueryFragment<__DB>, T9: QueryFragment<__DB>, T10: QueryFragment<__DB>, T11: QueryFragment<__DB>, T12: QueryFragment<__DB>, T13: QueryFragment<__DB>, T14: QueryFragment<__DB>, T15: QueryFragment<__DB>, T16: QueryFragment<__DB>, T17: QueryFragment<__DB>, T18: QueryFragment<__DB>, T19: QueryFragment<__DB>, T20: QueryFragment<__DB>, T21: QueryFragment<__DB>, T22: QueryFragment<__DB>, T23: QueryFragment<__DB>, T24: QueryFragment<__DB>, T25: QueryFragment<__DB>, T26: QueryFragment<__DB>, T27: QueryFragment<__DB>, T28: QueryFragment<__DB>, __DB: Backend> QueryFragment<__DB> for (T0, T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12, T13, T14, T15, T16, T17, T18, T19, T20, T21, T22, T23, T24, T25, T26, T27, T28)

Source§

fn walk_ast<'b>(&'b self, out: AstPass<'_, 'b, __DB>) -> QueryResult<()>

Source§

impl<T0: QueryFragment<__DB>, T1: QueryFragment<__DB>, T2: QueryFragment<__DB>, T3: QueryFragment<__DB>, T4: QueryFragment<__DB>, T5: QueryFragment<__DB>, T6: QueryFragment<__DB>, T7: QueryFragment<__DB>, T8: QueryFragment<__DB>, T9: QueryFragment<__DB>, T10: QueryFragment<__DB>, T11: QueryFragment<__DB>, T12: QueryFragment<__DB>, T13: QueryFragment<__DB>, T14: QueryFragment<__DB>, T15: QueryFragment<__DB>, T16: QueryFragment<__DB>, T17: QueryFragment<__DB>, T18: QueryFragment<__DB>, T19: QueryFragment<__DB>, T20: QueryFragment<__DB>, T21: QueryFragment<__DB>, T22: QueryFragment<__DB>, T23: QueryFragment<__DB>, T24: QueryFragment<__DB>, T25: QueryFragment<__DB>, T26: QueryFragment<__DB>, T27: QueryFragment<__DB>, __DB: Backend> QueryFragment<__DB> for (T0, T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12, T13, T14, T15, T16, T17, T18, T19, T20, T21, T22, T23, T24, T25, T26, T27)

Source§

fn walk_ast<'b>(&'b self, out: AstPass<'_, 'b, __DB>) -> QueryResult<()>

Source§

impl<T0: QueryFragment<__DB>, T1: QueryFragment<__DB>, T2: QueryFragment<__DB>, T3: QueryFragment<__DB>, T4: QueryFragment<__DB>, T5: QueryFragment<__DB>, T6: QueryFragment<__DB>, T7: QueryFragment<__DB>, T8: QueryFragment<__DB>, T9: QueryFragment<__DB>, T10: QueryFragment<__DB>, T11: QueryFragment<__DB>, T12: QueryFragment<__DB>, T13: QueryFragment<__DB>, T14: QueryFragment<__DB>, T15: QueryFragment<__DB>, T16: QueryFragment<__DB>, T17: QueryFragment<__DB>, T18: QueryFragment<__DB>, T19: QueryFragment<__DB>, T20: QueryFragment<__DB>, T21: QueryFragment<__DB>, T22: QueryFragment<__DB>, T23: QueryFragment<__DB>, T24: QueryFragment<__DB>, T25: QueryFragment<__DB>, T26: QueryFragment<__DB>, __DB: Backend> QueryFragment<__DB> for (T0, T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12, T13, T14, T15, T16, T17, T18, T19, T20, T21, T22, T23, T24, T25, T26)

Source§

fn walk_ast<'b>(&'b self, out: AstPass<'_, 'b, __DB>) -> QueryResult<()>

Source§

impl<T0: QueryFragment<__DB>, T1: QueryFragment<__DB>, T2: QueryFragment<__DB>, T3: QueryFragment<__DB>, T4: QueryFragment<__DB>, T5: QueryFragment<__DB>, T6: QueryFragment<__DB>, T7: QueryFragment<__DB>, T8: QueryFragment<__DB>, T9: QueryFragment<__DB>, T10: QueryFragment<__DB>, T11: QueryFragment<__DB>, T12: QueryFragment<__DB>, T13: QueryFragment<__DB>, T14: QueryFragment<__DB>, T15: QueryFragment<__DB>, T16: QueryFragment<__DB>, T17: QueryFragment<__DB>, T18: QueryFragment<__DB>, T19: QueryFragment<__DB>, T20: QueryFragment<__DB>, T21: QueryFragment<__DB>, T22: QueryFragment<__DB>, T23: QueryFragment<__DB>, T24: QueryFragment<__DB>, T25: QueryFragment<__DB>, __DB: Backend> QueryFragment<__DB> for (T0, T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12, T13, T14, T15, T16, T17, T18, T19, T20, T21, T22, T23, T24, T25)

Source§

fn walk_ast<'b>(&'b self, out: AstPass<'_, 'b, __DB>) -> QueryResult<()>

Source§

impl<T0: QueryFragment<__DB>, T1: QueryFragment<__DB>, T2: QueryFragment<__DB>, T3: QueryFragment<__DB>, T4: QueryFragment<__DB>, T5: QueryFragment<__DB>, T6: QueryFragment<__DB>, T7: QueryFragment<__DB>, T8: QueryFragment<__DB>, T9: QueryFragment<__DB>, T10: QueryFragment<__DB>, T11: QueryFragment<__DB>, T12: QueryFragment<__DB>, T13: QueryFragment<__DB>, T14: QueryFragment<__DB>, T15: QueryFragment<__DB>, T16: QueryFragment<__DB>, T17: QueryFragment<__DB>, T18: QueryFragment<__DB>, T19: QueryFragment<__DB>, T20: QueryFragment<__DB>, T21: QueryFragment<__DB>, T22: QueryFragment<__DB>, T23: QueryFragment<__DB>, T24: QueryFragment<__DB>, __DB: Backend> QueryFragment<__DB> for (T0, T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12, T13, T14, T15, T16, T17, T18, T19, T20, T21, T22, T23, T24)

Source§

fn walk_ast<'b>(&'b self, out: AstPass<'_, 'b, __DB>) -> QueryResult<()>

Source§

impl<T0: QueryFragment<__DB>, T1: QueryFragment<__DB>, T2: QueryFragment<__DB>, T3: QueryFragment<__DB>, T4: QueryFragment<__DB>, T5: QueryFragment<__DB>, T6: QueryFragment<__DB>, T7: QueryFragment<__DB>, T8: QueryFragment<__DB>, T9: QueryFragment<__DB>, T10: QueryFragment<__DB>, T11: QueryFragment<__DB>, T12: QueryFragment<__DB>, T13: QueryFragment<__DB>, T14: QueryFragment<__DB>, T15: QueryFragment<__DB>, T16: QueryFragment<__DB>, T17: QueryFragment<__DB>, T18: QueryFragment<__DB>, T19: QueryFragment<__DB>, T20: QueryFragment<__DB>, T21: QueryFragment<__DB>, T22: QueryFragment<__DB>, T23: QueryFragment<__DB>, __DB: Backend> QueryFragment<__DB> for (T0, T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12, T13, T14, T15, T16, T17, T18, T19, T20, T21, T22, T23)

Source§

fn walk_ast<'b>(&'b self, out: AstPass<'_, 'b, __DB>) -> QueryResult<()>

Source§

impl<T0: QueryFragment<__DB>, T1: QueryFragment<__DB>, T2: QueryFragment<__DB>, T3: QueryFragment<__DB>, T4: QueryFragment<__DB>, T5: QueryFragment<__DB>, T6: QueryFragment<__DB>, T7: QueryFragment<__DB>, T8: QueryFragment<__DB>, T9: QueryFragment<__DB>, T10: QueryFragment<__DB>, T11: QueryFragment<__DB>, T12: QueryFragment<__DB>, T13: QueryFragment<__DB>, T14: QueryFragment<__DB>, T15: QueryFragment<__DB>, T16: QueryFragment<__DB>, T17: QueryFragment<__DB>, T18: QueryFragment<__DB>, T19: QueryFragment<__DB>, T20: QueryFragment<__DB>, T21: QueryFragment<__DB>, T22: QueryFragment<__DB>, __DB: Backend> QueryFragment<__DB> for (T0, T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12, T13, T14, T15, T16, T17, T18, T19, T20, T21, T22)

Source§

fn walk_ast<'b>(&'b self, out: AstPass<'_, 'b, __DB>) -> QueryResult<()>

Source§

impl<T0: QueryFragment<__DB>, T1: QueryFragment<__DB>, T2: QueryFragment<__DB>, T3: QueryFragment<__DB>, T4: QueryFragment<__DB>, T5: QueryFragment<__DB>, T6: QueryFragment<__DB>, T7: QueryFragment<__DB>, T8: QueryFragment<__DB>, T9: QueryFragment<__DB>, T10: QueryFragment<__DB>, T11: QueryFragment<__DB>, T12: QueryFragment<__DB>, T13: QueryFragment<__DB>, T14: QueryFragment<__DB>, T15: QueryFragment<__DB>, T16: QueryFragment<__DB>, T17: QueryFragment<__DB>, T18: QueryFragment<__DB>, T19: QueryFragment<__DB>, T20: QueryFragment<__DB>, T21: QueryFragment<__DB>, __DB: Backend> QueryFragment<__DB> for (T0, T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12, T13, T14, T15, T16, T17, T18, T19, T20, T21)

Source§

fn walk_ast<'b>(&'b self, out: AstPass<'_, 'b, __DB>) -> QueryResult<()>

Source§

impl<T0: QueryFragment<__DB>, T1: QueryFragment<__DB>, T2: QueryFragment<__DB>, T3: QueryFragment<__DB>, T4: QueryFragment<__DB>, T5: QueryFragment<__DB>, T6: QueryFragment<__DB>, T7: QueryFragment<__DB>, T8: QueryFragment<__DB>, T9: QueryFragment<__DB>, T10: QueryFragment<__DB>, T11: QueryFragment<__DB>, T12: QueryFragment<__DB>, T13: QueryFragment<__DB>, T14: QueryFragment<__DB>, T15: QueryFragment<__DB>, T16: QueryFragment<__DB>, T17: QueryFragment<__DB>, T18: QueryFragment<__DB>, T19: QueryFragment<__DB>, T20: QueryFragment<__DB>, __DB: Backend> QueryFragment<__DB> for (T0, T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12, T13, T14, T15, T16, T17, T18, T19, T20)

Source§

fn walk_ast<'b>(&'b self, out: AstPass<'_, 'b, __DB>) -> QueryResult<()>

Source§

impl<T0: QueryFragment<__DB>, T1: QueryFragment<__DB>, T2: QueryFragment<__DB>, T3: QueryFragment<__DB>, T4: QueryFragment<__DB>, T5: QueryFragment<__DB>, T6: QueryFragment<__DB>, T7: QueryFragment<__DB>, T8: QueryFragment<__DB>, T9: QueryFragment<__DB>, T10: QueryFragment<__DB>, T11: QueryFragment<__DB>, T12: QueryFragment<__DB>, T13: QueryFragment<__DB>, T14: QueryFragment<__DB>, T15: QueryFragment<__DB>, T16: QueryFragment<__DB>, T17: QueryFragment<__DB>, T18: QueryFragment<__DB>, T19: QueryFragment<__DB>, __DB: Backend> QueryFragment<__DB> for (T0, T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12, T13, T14, T15, T16, T17, T18, T19)

Source§

fn walk_ast<'b>(&'b self, out: AstPass<'_, 'b, __DB>) -> QueryResult<()>

Source§

impl<T0: QueryFragment<__DB>, T1: QueryFragment<__DB>, T2: QueryFragment<__DB>, T3: QueryFragment<__DB>, T4: QueryFragment<__DB>, T5: QueryFragment<__DB>, T6: QueryFragment<__DB>, T7: QueryFragment<__DB>, T8: QueryFragment<__DB>, T9: QueryFragment<__DB>, T10: QueryFragment<__DB>, T11: QueryFragment<__DB>, T12: QueryFragment<__DB>, T13: QueryFragment<__DB>, T14: QueryFragment<__DB>, T15: QueryFragment<__DB>, T16: QueryFragment<__DB>, T17: QueryFragment<__DB>, T18: QueryFragment<__DB>, __DB: Backend> QueryFragment<__DB> for (T0, T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12, T13, T14, T15, T16, T17, T18)

Source§

fn walk_ast<'b>(&'b self, out: AstPass<'_, 'b, __DB>) -> QueryResult<()>

Source§

impl<T0: QueryFragment<__DB>, T1: QueryFragment<__DB>, T2: QueryFragment<__DB>, T3: QueryFragment<__DB>, T4: QueryFragment<__DB>, T5: QueryFragment<__DB>, T6: QueryFragment<__DB>, T7: QueryFragment<__DB>, T8: QueryFragment<__DB>, T9: QueryFragment<__DB>, T10: QueryFragment<__DB>, T11: QueryFragment<__DB>, T12: QueryFragment<__DB>, T13: QueryFragment<__DB>, T14: QueryFragment<__DB>, T15: QueryFragment<__DB>, T16: QueryFragment<__DB>, T17: QueryFragment<__DB>, __DB: Backend> QueryFragment<__DB> for (T0, T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12, T13, T14, T15, T16, T17)

Source§

fn walk_ast<'b>(&'b self, out: AstPass<'_, 'b, __DB>) -> QueryResult<()>

Source§

impl<T0: QueryFragment<__DB>, T1: QueryFragment<__DB>, T2: QueryFragment<__DB>, T3: QueryFragment<__DB>, T4: QueryFragment<__DB>, T5: QueryFragment<__DB>, T6: QueryFragment<__DB>, T7: QueryFragment<__DB>, T8: QueryFragment<__DB>, T9: QueryFragment<__DB>, T10: QueryFragment<__DB>, T11: QueryFragment<__DB>, T12: QueryFragment<__DB>, T13: QueryFragment<__DB>, T14: QueryFragment<__DB>, T15: QueryFragment<__DB>, T16: QueryFragment<__DB>, __DB: Backend> QueryFragment<__DB> for (T0, T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12, T13, T14, T15, T16)

Source§

fn walk_ast<'b>(&'b self, out: AstPass<'_, 'b, __DB>) -> QueryResult<()>

Source§

impl<T0: QueryFragment<__DB>, T1: QueryFragment<__DB>, T2: QueryFragment<__DB>, T3: QueryFragment<__DB>, T4: QueryFragment<__DB>, T5: QueryFragment<__DB>, T6: QueryFragment<__DB>, T7: QueryFragment<__DB>, T8: QueryFragment<__DB>, T9: QueryFragment<__DB>, T10: QueryFragment<__DB>, T11: QueryFragment<__DB>, T12: QueryFragment<__DB>, T13: QueryFragment<__DB>, T14: QueryFragment<__DB>, T15: QueryFragment<__DB>, __DB: Backend> QueryFragment<__DB> for (T0, T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12, T13, T14, T15)

Source§

fn walk_ast<'b>(&'b self, out: AstPass<'_, 'b, __DB>) -> QueryResult<()>

Source§

impl<T0: QueryFragment<__DB>, T1: QueryFragment<__DB>, T2: QueryFragment<__DB>, T3: QueryFragment<__DB>, T4: QueryFragment<__DB>, T5: QueryFragment<__DB>, T6: QueryFragment<__DB>, T7: QueryFragment<__DB>, T8: QueryFragment<__DB>, T9: QueryFragment<__DB>, T10: QueryFragment<__DB>, T11: QueryFragment<__DB>, T12: QueryFragment<__DB>, T13: QueryFragment<__DB>, T14: QueryFragment<__DB>, __DB: Backend> QueryFragment<__DB> for (T0, T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12, T13, T14)

Source§

fn walk_ast<'b>(&'b self, out: AstPass<'_, 'b, __DB>) -> QueryResult<()>

Source§

impl<T0: QueryFragment<__DB>, T1: QueryFragment<__DB>, T2: QueryFragment<__DB>, T3: QueryFragment<__DB>, T4: QueryFragment<__DB>, T5: QueryFragment<__DB>, T6: QueryFragment<__DB>, T7: QueryFragment<__DB>, T8: QueryFragment<__DB>, T9: QueryFragment<__DB>, T10: QueryFragment<__DB>, T11: QueryFragment<__DB>, T12: QueryFragment<__DB>, T13: QueryFragment<__DB>, __DB: Backend> QueryFragment<__DB> for (T0, T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12, T13)

Source§

fn walk_ast<'b>(&'b self, out: AstPass<'_, 'b, __DB>) -> QueryResult<()>

Source§

impl<T0: QueryFragment<__DB>, T1: QueryFragment<__DB>, T2: QueryFragment<__DB>, T3: QueryFragment<__DB>, T4: QueryFragment<__DB>, T5: QueryFragment<__DB>, T6: QueryFragment<__DB>, T7: QueryFragment<__DB>, T8: QueryFragment<__DB>, T9: QueryFragment<__DB>, T10: QueryFragment<__DB>, T11: QueryFragment<__DB>, T12: QueryFragment<__DB>, __DB: Backend> QueryFragment<__DB> for (T0, T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12)

Source§

fn walk_ast<'b>(&'b self, out: AstPass<'_, 'b, __DB>) -> QueryResult<()>

Source§

impl<T0: QueryFragment<__DB>, T1: QueryFragment<__DB>, T2: QueryFragment<__DB>, T3: QueryFragment<__DB>, T4: QueryFragment<__DB>, T5: QueryFragment<__DB>, T6: QueryFragment<__DB>, T7: QueryFragment<__DB>, T8: QueryFragment<__DB>, T9: QueryFragment<__DB>, T10: QueryFragment<__DB>, T11: QueryFragment<__DB>, __DB: Backend> QueryFragment<__DB> for (T0, T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11)

Source§

fn walk_ast<'b>(&'b self, out: AstPass<'_, 'b, __DB>) -> QueryResult<()>

Source§

impl<T0: QueryFragment<__DB>, T1: QueryFragment<__DB>, T2: QueryFragment<__DB>, T3: QueryFragment<__DB>, T4: QueryFragment<__DB>, T5: QueryFragment<__DB>, T6: QueryFragment<__DB>, T7: QueryFragment<__DB>, T8: QueryFragment<__DB>, T9: QueryFragment<__DB>, T10: QueryFragment<__DB>, __DB: Backend> QueryFragment<__DB> for (T0, T1, T2, T3, T4, T5, T6, T7, T8, T9, T10)

Source§

fn walk_ast<'b>(&'b self, out: AstPass<'_, 'b, __DB>) -> QueryResult<()>

Source§

impl<T0: QueryFragment<__DB>, T1: QueryFragment<__DB>, T2: QueryFragment<__DB>, T3: QueryFragment<__DB>, T4: QueryFragment<__DB>, T5: QueryFragment<__DB>, T6: QueryFragment<__DB>, T7: QueryFragment<__DB>, T8: QueryFragment<__DB>, T9: QueryFragment<__DB>, __DB: Backend> QueryFragment<__DB> for (T0, T1, T2, T3, T4, T5, T6, T7, T8, T9)

Source§

fn walk_ast<'b>(&'b self, out: AstPass<'_, 'b, __DB>) -> QueryResult<()>

Source§

impl<T0: QueryFragment<__DB>, T1: QueryFragment<__DB>, T2: QueryFragment<__DB>, T3: QueryFragment<__DB>, T4: QueryFragment<__DB>, T5: QueryFragment<__DB>, T6: QueryFragment<__DB>, T7: QueryFragment<__DB>, T8: QueryFragment<__DB>, __DB: Backend> QueryFragment<__DB> for (T0, T1, T2, T3, T4, T5, T6, T7, T8)

Source§

fn walk_ast<'b>(&'b self, out: AstPass<'_, 'b, __DB>) -> QueryResult<()>

Source§

impl<T0: QueryFragment<__DB>, T1: QueryFragment<__DB>, T2: QueryFragment<__DB>, T3: QueryFragment<__DB>, T4: QueryFragment<__DB>, T5: QueryFragment<__DB>, T6: QueryFragment<__DB>, T7: QueryFragment<__DB>, __DB: Backend> QueryFragment<__DB> for (T0, T1, T2, T3, T4, T5, T6, T7)

Source§

fn walk_ast<'b>(&'b self, out: AstPass<'_, 'b, __DB>) -> QueryResult<()>

Source§

impl<T0: QueryFragment<__DB>, T1: QueryFragment<__DB>, T2: QueryFragment<__DB>, T3: QueryFragment<__DB>, T4: QueryFragment<__DB>, T5: QueryFragment<__DB>, T6: QueryFragment<__DB>, __DB: Backend> QueryFragment<__DB> for (T0, T1, T2, T3, T4, T5, T6)

Source§

fn walk_ast<'b>(&'b self, out: AstPass<'_, 'b, __DB>) -> QueryResult<()>

Source§

impl<T0: QueryFragment<__DB>, T1: QueryFragment<__DB>, T2: QueryFragment<__DB>, T3: QueryFragment<__DB>, T4: QueryFragment<__DB>, T5: QueryFragment<__DB>, __DB: Backend> QueryFragment<__DB> for (T0, T1, T2, T3, T4, T5)

Source§

fn walk_ast<'b>(&'b self, out: AstPass<'_, 'b, __DB>) -> QueryResult<()>

Source§

impl<T0: QueryFragment<__DB>, T1: QueryFragment<__DB>, T2: QueryFragment<__DB>, T3: QueryFragment<__DB>, T4: QueryFragment<__DB>, __DB: Backend> QueryFragment<__DB> for (T0, T1, T2, T3, T4)

Source§

fn walk_ast<'b>(&'b self, out: AstPass<'_, 'b, __DB>) -> QueryResult<()>

Source§

impl<T0: QueryFragment<__DB>, T1: QueryFragment<__DB>, T2: QueryFragment<__DB>, T3: QueryFragment<__DB>, __DB: Backend> QueryFragment<__DB> for (T0, T1, T2, T3)

Source§

fn walk_ast<'b>(&'b self, out: AstPass<'_, 'b, __DB>) -> QueryResult<()>

Source§

impl<T0: QueryFragment<__DB>, T1: QueryFragment<__DB>, T2: QueryFragment<__DB>, __DB: Backend> QueryFragment<__DB> for (T0, T1, T2)

Source§

fn walk_ast<'b>(&'b self, out: AstPass<'_, 'b, __DB>) -> QueryResult<()>

Source§

impl<T0: QueryFragment<__DB>, T1: QueryFragment<__DB>, __DB: Backend> QueryFragment<__DB> for (T0, T1)

Source§

fn walk_ast<'b>(&'b self, out: AstPass<'_, 'b, __DB>) -> QueryResult<()>

Source§

impl<T0: QueryFragment<__DB>, __DB: Backend> QueryFragment<__DB> for (T0,)

Source§

fn walk_ast<'b>(&'b self, out: AstPass<'_, 'b, __DB>) -> QueryResult<()>

Source§

impl<T, DB> QueryFragment<DB> for Option<T>
where DB: Backend, T: QueryFragment<DB>,

Source§

fn walk_ast<'b>(&'b self, out: AstPass<'_, 'b, DB>) -> QueryResult<()>

Source§

impl<T, DB> QueryFragment<DB> for Box<T>
where DB: Backend, T: QueryFragment<DB> + ?Sized,

Source§

fn walk_ast<'b>(&'b self, pass: AstPass<'_, 'b, DB>) -> QueryResult<()>

Implementors§

Source§

impl QueryFragment<Mysql> for InsertOrIgnore

Available on crate feature mysql_backend only.
Source§

impl QueryFragment<Mysql> for LimitOffsetClause<NoLimitClause, NoOffsetClause>

Available on crate feature mysql_backend only.
Source§

impl QueryFragment<Mysql> for Replace

Available on crate feature mysql_backend only.
Source§

impl QueryFragment<Sqlite> for InsertOrIgnore

Available on crate feature sqlite only.
Source§

impl QueryFragment<Sqlite> for LimitOffsetClause<NoLimitClause, NoOffsetClause>

Available on crate feature sqlite only.
Source§

impl QueryFragment<Sqlite> for Replace

Available on crate feature sqlite only.
Source§

impl<'a> QueryFragment<Mysql> for BoxedLimitOffsetClause<'a, Mysql>

Available on crate feature mysql_backend only.
Source§

impl<'a> QueryFragment<Pg> for BoxedLimitOffsetClause<'a, Pg>

Available on crate feature postgres_backend only.
Source§

impl<'a> QueryFragment<Sqlite> for BoxedLimitOffsetClause<'a, Sqlite>

Available on crate feature sqlite only.
Source§

impl<'a, C> QueryFragment<Pg> for TransactionBuilder<'a, C>

Available on crate feature postgres_backend only.
Source§

impl<'a, ST, QS, DB, GB> QueryFragment<DB> for BoxedSelectStatement<'a, ST, QS, DB, GB>
where DB: Backend, Self: QueryFragment<DB, DB::SelectStatementSyntax>,

Source§

impl<'a, ST, QS, DB, GB> QueryFragment<DB, AnsiSqlSelectStatement> for BoxedSelectStatement<'a, ST, QS, DB, GB>

Source§

impl<DB> QueryFragment<DB> for All

Source§

impl<DB> QueryFragment<DB> for Distinct

Source§

impl<DB> QueryFragment<DB> for Except

Source§

impl<DB> QueryFragment<DB> for Intersect

Source§

impl<DB> QueryFragment<DB> for NoFromClause
where Self: QueryFragment<DB, DB::EmptyFromClauseSyntax>, DB: Backend,

Source§

impl<DB> QueryFragment<DB> for NoLimitClause

Source§

impl<DB> QueryFragment<DB> for NoOffsetClause

Source§

impl<DB> QueryFragment<DB> for Union

Source§

impl<DB> QueryFragment<DB, AnsiSqlFromClauseSyntax> for NoFromClause
where DB: Backend<EmptyFromClauseSyntax = AnsiSqlFromClauseSyntax>,

Source§

impl<DB, Inner> QueryFragment<DB> for SqlQuery<Inner>

Source§

impl<DB, Query> QueryFragment<DB> for BoxedSqlQuery<'_, DB, Query>

Source§

impl<DB, T> QueryFragment<DB> for CollectedQuery<T>
where DB: Backend + DieselReserveSpecialization, for<'a> <DB as Backend>::BindCollector<'a>: MoveableBindCollector<DB, BindData = T>,

Source§

impl<DB: Backend> QueryFragment<DB> for now

Source§

impl<DB: Backend> QueryFragment<DB> for today

Source§

impl<Expr, DB> QueryFragment<DB> for LimitClause<Expr>

Source§

impl<Expr, DB> QueryFragment<DB> for OffsetClause<Expr>

Source§

impl<Expr, DB> QueryFragment<DB> for ReturningClause<Expr>
where DB: Backend, Self: QueryFragment<DB, DB::ReturningClause>,

Source§

impl<Expr, DB> QueryFragment<DB, PgLikeReturningClause> for ReturningClause<Expr>
where DB: Backend<ReturningClause = PgLikeReturningClause>, Expr: QueryFragment<DB>,

Source§

impl<F, S, D, W, O, LOf, G, H, LC, DB> QueryFragment<DB> for SelectStatement<F, S, D, W, O, LOf, G, H, LC>
where DB: Backend, Self: QueryFragment<DB, DB::SelectStatementSyntax>,

Source§

impl<F, S, D, W, O, LOf, G, H, LC, DB> QueryFragment<DB, AnsiSqlSelectStatement> for SelectStatement<F, S, D, W, O, LOf, G, H, LC>
where DB: Backend<SelectStatementSyntax = AnsiSqlSelectStatement>, S: QueryFragment<DB>, F: QueryFragment<DB>, D: QueryFragment<DB>, W: QueryFragment<DB>, O: QueryFragment<DB>, LOf: QueryFragment<DB>, G: QueryFragment<DB>, H: QueryFragment<DB>, LC: QueryFragment<DB>,

Source§

impl<L> QueryFragment<Mysql> for LimitOffsetClause<LimitClause<L>, NoOffsetClause>

Available on crate feature mysql_backend only.
Source§

impl<L> QueryFragment<Sqlite> for LimitOffsetClause<LimitClause<L>, NoOffsetClause>

Available on crate feature sqlite only.
Source§

impl<L, O> QueryFragment<Mysql> for LimitOffsetClause<LimitClause<L>, OffsetClause<O>>

Available on crate feature mysql_backend only.
Source§

impl<L, O> QueryFragment<Pg> for LimitOffsetClause<L, O>

Available on crate feature postgres_backend only.
Source§

impl<L, O> QueryFragment<Sqlite> for LimitOffsetClause<LimitClause<L>, OffsetClause<O>>

Available on crate feature sqlite only.
Source§

impl<L, R, DB> QueryFragment<DB> for Concat<L, R>
where DB: Backend, Self: QueryFragment<DB, DB::ConcatClause>,

Source§

impl<L, R, DB> QueryFragment<DB, ConcatWithPipesClause> for Concat<L, R>
where L: QueryFragment<DB>, R: QueryFragment<DB>, DB: Backend + SqlDialect<ConcatClause = ConcatWithPipesClause>,

Source§

impl<O> QueryFragment<Sqlite> for LimitOffsetClause<NoLimitClause, OffsetClause<O>>

Available on crate feature sqlite only.
Source§

impl<Query, Value, DB> QueryFragment<DB> for UncheckedBind<Query, Value>
where DB: Backend, Query: QueryFragment<DB>, Value: QueryFragment<DB>,

Source§

impl<S> QueryFragment<Pg> for Only<S>
where S: QueryFragment<Pg>,

Available on crate feature postgres_backend only.
Source§

impl<S, C, DB> QueryFragment<DB> for AliasedField<S, C>
where S: AliasSource, DB: Backend, C: Column<Table = S::Target>,

Source§

impl<S, DB> QueryFragment<DB> for Alias<S>
where S: AliasSource, DB: Backend, Self: QueryFragment<DB, DB::AliasSyntax>,

Source§

impl<S, DB> QueryFragment<DB, AsAliasSyntax> for Alias<S>
where S: AliasSource, DB: Backend, S::Target: QueryFragment<DB>,

Source§

impl<S, TSM> QueryFragment<Pg> for Tablesample<S, TSM>
where S: QueryFragment<Pg>, TSM: TablesampleMethod,

Available on crate feature postgres_backend only.
Source§

impl<ST, I, DB> QueryFragment<DB> for Many<ST, I>
where Self: QueryFragment<DB, DB::ArrayComparison>, DB: Backend,

Available on crate feature i-implement-a-third-party-backend-and-opt-into-breaking-changes only.
Source§

impl<ST, I, DB> QueryFragment<DB, AnsiSqlArrayComparison> for Many<ST, I>
where DB: Backend + HasSqlType<ST> + SqlDialect<ArrayComparison = AnsiSqlArrayComparison>, ST: SingleValue, I: ToSql<ST, DB>,

Available on crate feature i-implement-a-third-party-backend-and-opt-into-breaking-changes only.
Source§

impl<ST, T, DB> QueryFragment<DB> for SqlLiteral<ST, T>
where DB: Backend, T: QueryFragment<DB>,

Source§

impl<T> QueryFragment<Pg> for DistinctOnClause<T>
where T: QueryFragment<Pg>,

Available on crate feature postgres_backend only.
Source§

impl<T, DB> QueryFragment<DB> for Exists<T>
where DB: Backend, Self: QueryFragment<DB, DB::ExistsSyntax>,

Available on crate feature i-implement-a-third-party-backend-and-opt-into-breaking-changes only.
Source§

impl<T, DB> QueryFragment<DB, AnsiSqlExistsSyntax> for Exists<T>
where DB: Backend + SqlDialect<ExistsSyntax = AnsiSqlExistsSyntax>, T: QueryFragment<DB>,

Available on crate feature i-implement-a-third-party-backend-and-opt-into-breaking-changes only.
Source§

impl<T, Tab, DB> QueryFragment<DB> for ValuesClause<T, Tab>
where DB: Backend, Tab: Table, T: InsertValues<DB, Tab>, DefaultValues: QueryFragment<DB>,

Source§

impl<T, U, DB> QueryFragment<DB> for In<T, U>
where DB: Backend, Self: QueryFragment<DB, DB::ArrayComparison>,

Available on crate feature i-implement-a-third-party-backend-and-opt-into-breaking-changes only.
Source§

impl<T, U, DB> QueryFragment<DB> for NotIn<T, U>
where DB: Backend, Self: QueryFragment<DB, DB::ArrayComparison>,

Available on crate feature i-implement-a-third-party-backend-and-opt-into-breaking-changes only.
Source§

impl<T, U, DB> QueryFragment<DB, AnsiSqlArrayComparison> for In<T, U>
where DB: Backend + SqlDialect<ArrayComparison = AnsiSqlArrayComparison>, T: QueryFragment<DB>, U: QueryFragment<DB> + MaybeEmpty,

Available on crate feature i-implement-a-third-party-backend-and-opt-into-breaking-changes only.
Source§

impl<T, U, DB> QueryFragment<DB, AnsiSqlArrayComparison> for NotIn<T, U>
where DB: Backend + SqlDialect<ArrayComparison = AnsiSqlArrayComparison>, T: QueryFragment<DB>, U: QueryFragment<DB> + MaybeEmpty,

Available on crate feature i-implement-a-third-party-backend-and-opt-into-breaking-changes only.
Source§

impl<T, U, Op, Ret, DB> QueryFragment<DB> for InsertStatement<T, U, Op, Ret>
where DB: Backend + DieselReserveSpecialization, T: Table, T::FromClause: QueryFragment<DB>, U: QueryFragment<DB> + CanInsertInSingleQuery<DB>, Op: QueryFragment<DB>, Ret: QueryFragment<DB>,

Source§

impl<T, U, Ret, DB> QueryFragment<DB> for DeleteStatement<T, U, Ret>

Source§

impl<T, U, V, Ret, DB> QueryFragment<DB> for UpdateStatement<T, U, V, Ret>

Source§

impl<T: QueryFragment<Mysql>> QueryFragment<Mysql> for ParenthesisWrapper<T>

Available on crate feature mysql_backend only.
Source§

impl<T: QueryFragment<Pg>> QueryFragment<Pg> for ParenthesisWrapper<T>

Available on crate feature postgres_backend only.
Source§

impl<T: QueryFragment<Sqlite>> QueryFragment<Sqlite> for ParenthesisWrapper<T>

Available on crate feature sqlite only.
Source§

impl<Tab, DB, V, QId, const HAS_STATIC_QUERY_ID: bool> QueryFragment<DB> for BatchInsert<V, Tab, QId, HAS_STATIC_QUERY_ID>
where DB: Backend, Self: QueryFragment<DB, DB::BatchInsertSupport>,

Source§

impl<Tab, DB, V, QId, const HAS_STATIC_QUERY_ID: bool> QueryFragment<DB, PostgresLikeBatchInsertSupport> for BatchInsert<Vec<ValuesClause<V, Tab>>, Tab, QId, HAS_STATIC_QUERY_ID>

Source§

impl<Whens, E, DB> QueryFragment<DB> for CaseWhen<Whens, E>
where DB: Backend, Whens: QueryFragment<DB>, E: QueryFragment<DB>,