pub enum Predicate {
Show 14 variants
Eq {
column: String,
value: String,
},
Ne {
column: String,
value: String,
},
Lt {
column: String,
value: String,
},
Le {
column: String,
value: String,
},
Gt {
column: String,
value: String,
},
Ge {
column: String,
value: String,
},
Between {
column: String,
min: String,
max: String,
},
In {
column: String,
values: Vec<String>,
},
Like {
column: String,
pattern: String,
},
IsNull {
column: String,
},
IsNotNull {
column: String,
},
And(Box<Predicate>, Box<Predicate>),
Or(Box<Predicate>, Box<Predicate>),
Not(Box<Predicate>),
}Expand description
Query predicate for cost estimation
Variants§
Eq
Equality: column = value
Ne
Inequality: column != value
Lt
Less than: column < value
Le
Less than or equal: column <= value
Gt
Greater than: column > value
Ge
Greater than or equal: column >= value
Between
Between: column BETWEEN min AND max
In
In list: column IN (v1, v2, …)
Like
Like: column LIKE pattern
IsNull
Is null: column IS NULL
IsNotNull
Is not null: column IS NOT NULL
And(Box<Predicate>, Box<Predicate>)
And: pred1 AND pred2
Or(Box<Predicate>, Box<Predicate>)
Or: pred1 OR pred2
Not(Box<Predicate>)
Not: NOT pred
Implementations§
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Predicate
impl RefUnwindSafe for Predicate
impl Send for Predicate
impl Sync for Predicate
impl Unpin for Predicate
impl UnwindSafe for Predicate
Blanket Implementations§
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> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more