Skip to main content

coalesce

Function coalesce 

Source
pub fn coalesce<I, C>(columns: I) -> CoalesceExpr
where I: IntoIterator<Item = C>, C: IntoColumnName,
Expand description

Build a COALESCE(...) left-hand operand. The returned CoalesceExpr carries the column list; chain a comparator method (.lte, .eq, .is_null, …) to produce a FilterExpr the query builders can consume.

.where_(coalesce([
    task::next_attempt_at(),
    task::scheduled_at(),
    task::created_at(),
]).lte(now))