pub struct Collate<T, C> { /* private fields */ }Expand description
Represents the SQL COLLATE operator
Implementations§
Trait Implementations§
Source§impl<T, C, __Rhs> Add<__Rhs> for Collate<T, C>where
Self: Expression,
<Self as Expression>::SqlType: Add,
<<Self as Expression>::SqlType as Add>::Rhs: SqlType + SingleValue,
__Rhs: AsExpression<<<Self as Expression>::SqlType as Add>::Rhs>,
impl<T, C, __Rhs> Add<__Rhs> for Collate<T, C>where
Self: Expression,
<Self as Expression>::SqlType: Add,
<<Self as Expression>::SqlType as Add>::Rhs: SqlType + SingleValue,
__Rhs: AsExpression<<<Self as Expression>::SqlType as Add>::Rhs>,
Source§impl<T, C, __Rhs> Div<__Rhs> for Collate<T, C>where
Self: Expression,
<Self as Expression>::SqlType: Div,
<<Self as Expression>::SqlType as Div>::Rhs: SqlType + SingleValue,
__Rhs: AsExpression<<<Self as Expression>::SqlType as Div>::Rhs>,
impl<T, C, __Rhs> Div<__Rhs> for Collate<T, C>where
Self: Expression,
<Self as Expression>::SqlType: Div,
<<Self as Expression>::SqlType as Div>::Rhs: SqlType + SingleValue,
__Rhs: AsExpression<<<Self as Expression>::SqlType as Div>::Rhs>,
Source§impl<T, C> Expression for Collate<T, C>where
T: Expression,
impl<T, C> Expression for Collate<T, C>where
T: Expression,
Source§type SqlType = <T as Expression>::SqlType
type SqlType = <T as Expression>::SqlType
The type that this expression represents in SQL
Source§impl<T, C, __Rhs> Mul<__Rhs> for Collate<T, C>where
Self: Expression,
<Self as Expression>::SqlType: Mul,
<<Self as Expression>::SqlType as Mul>::Rhs: SqlType + SingleValue,
__Rhs: AsExpression<<<Self as Expression>::SqlType as Mul>::Rhs>,
impl<T, C, __Rhs> Mul<__Rhs> for Collate<T, C>where
Self: Expression,
<Self as Expression>::SqlType: Mul,
<<Self as Expression>::SqlType as Mul>::Rhs: SqlType + SingleValue,
__Rhs: AsExpression<<<Self as Expression>::SqlType as Mul>::Rhs>,
Source§impl<T, C, DB> QueryFragment<DB> for Collate<T, C>
impl<T, C, DB> QueryFragment<DB> for Collate<T, C>
Source§fn walk_ast<'b>(&'b self, out: AstPass<'_, 'b, DB>) -> QueryResult<()>
fn walk_ast<'b>(&'b self, out: AstPass<'_, 'b, DB>) -> QueryResult<()>
Walk over this
QueryFragment for all passes. Read moreSource§fn to_sql(&self, out: &mut DB::QueryBuilder, backend: &DB) -> QueryResult<()>
fn to_sql(&self, out: &mut DB::QueryBuilder, backend: &DB) -> QueryResult<()>
Converts this
QueryFragment to its SQL representation. Read moreSource§fn collect_binds<'b>(
&'b self,
out: &mut DB::BindCollector<'b>,
metadata_lookup: &mut DB::MetadataLookup,
backend: &'b DB,
) -> QueryResult<()>
fn collect_binds<'b>( &'b self, out: &mut DB::BindCollector<'b>, metadata_lookup: &mut DB::MetadataLookup, backend: &'b DB, ) -> QueryResult<()>
Serializes all bind parameters in this query. Read more
Source§fn is_safe_to_cache_prepared(&self, backend: &DB) -> QueryResult<bool>
fn is_safe_to_cache_prepared(&self, backend: &DB) -> QueryResult<bool>
Is this query safe to store in the prepared statement cache? Read more
Source§impl<T, C> QueryId for Collate<T, C>
impl<T, C> QueryId for Collate<T, C>
Source§impl<T, C, __Rhs> Sub<__Rhs> for Collate<T, C>where
Self: Expression,
<Self as Expression>::SqlType: Sub,
<<Self as Expression>::SqlType as Sub>::Rhs: SqlType + SingleValue,
__Rhs: AsExpression<<<Self as Expression>::SqlType as Sub>::Rhs>,
impl<T, C, __Rhs> Sub<__Rhs> for Collate<T, C>where
Self: Expression,
<Self as Expression>::SqlType: Sub,
<<Self as Expression>::SqlType as Sub>::Rhs: SqlType + SingleValue,
__Rhs: AsExpression<<<Self as Expression>::SqlType as Sub>::Rhs>,
Source§impl<T, C, GB> ValidGrouping<GB> for Collate<T, C>where
T: ValidGrouping<GB>,
impl<T, C, GB> ValidGrouping<GB> for Collate<T, C>where
T: ValidGrouping<GB>,
Source§type IsAggregate = <T as ValidGrouping<GB>>::IsAggregate
type IsAggregate = <T as ValidGrouping<GB>>::IsAggregate
Is this expression aggregate? Read more
impl<T, C, QS> AppearsOnTable<QS> for Collate<T, C>
impl<T, C, QS> SelectableExpression<QS> for Collate<T, C>
Auto Trait Implementations§
impl<T, C> Freeze for Collate<T, C>
impl<T, C> RefUnwindSafe for Collate<T, C>where
T: RefUnwindSafe,
C: RefUnwindSafe,
impl<T, C> Send for Collate<T, C>
impl<T, C> Sync for Collate<T, C>
impl<T, C> Unpin for Collate<T, C>
impl<T, C> UnwindSafe for Collate<T, C>where
T: UnwindSafe,
C: UnwindSafe,
Blanket Implementations§
Source§impl<T, ST> AsExpressionList<ST> for T
impl<T, ST> AsExpressionList<ST> for T
Source§type Expression = <T as IntoArrayExpression<ST>>::ArrayExpression
type Expression = <T as IntoArrayExpression<ST>>::ArrayExpression
👎Deprecated: Use
IntoArrayExpression insteadAvailable on crate feature
with-deprecated and non-crate feature without-deprecated only.The final output expression
Source§fn as_expression_list(self) -> <T as AsExpressionList<ST>>::Expression
fn as_expression_list(self) -> <T as AsExpressionList<ST>>::Expression
👎Deprecated: Use
IntoArrayExpression insteadAvailable on crate feature
with-deprecated and non-crate feature without-deprecated only.Perform the conversion
Source§impl<T> AggregateExpressionMethods for T
impl<T> AggregateExpressionMethods for T
Source§fn aggregate_distinct(self) -> AggregateDistinct<Self>where
Self: DistinctDsl,
fn aggregate_distinct(self) -> AggregateDistinct<Self>where
Self: DistinctDsl,
DISTINCT modifier for aggregate functions Read moreSource§fn aggregate_all(self) -> AggregateAll<Self>where
Self: AllDsl,
fn aggregate_all(self) -> AggregateAll<Self>where
Self: AllDsl,
ALL modifier for aggregate functions Read moreSource§fn aggregate_filter<P>(self, f: P) -> AggregateFilter<Self, P>
fn aggregate_filter<P>(self, f: P) -> AggregateFilter<Self, P>
Add an aggregate function filter Read more
Source§fn aggregate_order<O>(self, o: O) -> AggregateOrder<Self, O>where
Self: OrderAggregateDsl<O>,
fn aggregate_order<O>(self, o: O) -> AggregateOrder<Self, O>where
Self: OrderAggregateDsl<O>,
Add an aggregate function order Read more
Source§impl<T, ST> AsExpression<ST> for T
impl<T, ST> AsExpression<ST> for T
Source§type Expression = T
type Expression = T
The expression being returned
Source§fn as_expression(self) -> T
fn as_expression(self) -> T
Perform the conversion
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> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Downcast for Twhere
T: Any,
impl<T> Downcast for Twhere
T: Any,
Source§fn into_any(self: Box<T>) -> Box<dyn Any>
fn into_any(self: Box<T>) -> Box<dyn Any>
Converts
Box<dyn Trait> (where Trait: Downcast) to Box<dyn Any>, which can then be
downcast into Box<dyn ConcreteType> where ConcreteType implements Trait.Source§fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
Converts
Rc<Trait> (where Trait: Downcast) to Rc<Any>, which can then be further
downcast into Rc<ConcreteType> where ConcreteType implements Trait.Source§fn as_any(&self) -> &(dyn Any + 'static)
fn as_any(&self) -> &(dyn Any + 'static)
Converts
&Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot
generate &Any’s vtable from &Trait’s.Source§fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
Converts
&mut Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot
generate &mut Any’s vtable from &mut Trait’s.Source§impl<T> DowncastSend for T
impl<T> DowncastSend for T
Source§impl<Conn, DB, T> ExecuteDsl<Conn, DB> for T
impl<Conn, DB, T> ExecuteDsl<Conn, DB> for T
Source§impl<ST, T> IntoArrayExpression<ST> for T
impl<ST, T> IntoArrayExpression<ST> for T
Source§type ArrayExpression = <T as AsExpression<Array<ST>>>::Expression
type ArrayExpression = <T as AsExpression<Array<ST>>>::Expression
Available on crate feature
postgres_backend only.Type of the expression returned by IntoArrayExpression::into_array_expression
Source§fn into_array_expression(
self,
) -> <T as IntoArrayExpression<ST>>::ArrayExpression
fn into_array_expression( self, ) -> <T as IntoArrayExpression<ST>>::ArrayExpression
Available on crate feature
postgres_backend only.Construct the diesel query dsl representation of
the
ARRAY (values) clause for the given typeSource§impl<T> IntoSql for T
impl<T> IntoSql for T
Source§impl<T> NullableExpressionMethods for Twhere
T: Expression,
impl<T> NullableExpressionMethods for Twhere
T: Expression,
Source§fn nullable(self) -> Nullable<Self>
fn nullable(self) -> Nullable<Self>
Converts this potentially non-null expression into one which is treated
as nullable. This method has no impact on the generated SQL, and is only
used to allow certain comparisons that would otherwise fail to compile. Read more
Source§fn assume_not_null(self) -> AssumeNotNull<Self>
fn assume_not_null(self) -> AssumeNotNull<Self>
Converts this potentially nullable expression into one which will be assumed
to be not-null. This method has no impact on the generated SQL, however it will
enable you to attempt deserialization of the returned value in a non-
Option. Read moreSource§impl<T> PgExpressionMethods for Twhere
T: Expression,
impl<T> PgExpressionMethods for Twhere
T: Expression,
Source§fn is_not_distinct_from<T>(self, other: T) -> IsNotDistinctFrom<Self, T>
fn is_not_distinct_from<T>(self, other: T) -> IsNotDistinctFrom<Self, T>
Available on crate feature
postgres_backend only.Creates a PostgreSQL
IS NOT DISTINCT FROM expression. Read moreSource§fn is_distinct_from<T>(self, other: T) -> IsDistinctFrom<Self, T>
fn is_distinct_from<T>(self, other: T) -> IsDistinctFrom<Self, T>
Available on crate feature
postgres_backend only.Creates a PostgreSQL
IS DISTINCT FROM expression. Read moreSource§fn is_contained_by_range<T>(self, other: T) -> IsContainedByRange<Self, T>
fn is_contained_by_range<T>(self, other: T) -> IsContainedByRange<Self, T>
Available on crate feature
postgres_backend only.Creates a PostgreSQL
<@ expression. Read moreSource§impl<T, DB> QueryFragmentForCachedStatement<DB> for T
impl<T, DB> QueryFragmentForCachedStatement<DB> for T
Source§impl<T> SqliteExpressionMethods for Twhere
T: Expression,
impl<T> SqliteExpressionMethods for Twhere
T: Expression,
Source§impl<T> UntypedExpressionMethods for Twhere
T: Expression<SqlType = Untyped>,
impl<T> UntypedExpressionMethods for Twhere
T: Expression<SqlType = Untyped>,
Source§impl<T> WindowExpressionMethods for T
impl<T> WindowExpressionMethods for T
Source§fn over(self) -> Over<Self>where
Self: OverDsl,
fn over(self) -> Over<Self>where
Self: OverDsl,
Turn a function call into a window function call Read more
Source§fn window_filter<P>(self, f: P) -> WindowFilter<Self, P>
fn window_filter<P>(self, f: P) -> WindowFilter<Self, P>
Add a filter to the current window function Read more
Source§fn partition_by<E>(self, expr: E) -> PartitionBy<Self, E>where
Self: PartitionByDsl<E>,
fn partition_by<E>(self, expr: E) -> PartitionBy<Self, E>where
Self: PartitionByDsl<E>,
Add a partition clause to the current window function Read more
Source§fn window_order<E>(self, expr: E) -> WindowOrder<Self, E>where
Self: OrderWindowDsl<E>,
fn window_order<E>(self, expr: E) -> WindowOrder<Self, E>where
Self: OrderWindowDsl<E>,
Add a order clause to the current window function Read more