pub enum Expr {
Show 24 variants
Identifier(String),
CompoundIdentifier {
alias: String,
ident: String,
},
IsNull(Box<Expr>),
IsNotNull(Box<Expr>),
InList {
expr: Box<Expr>,
list: Vec<Expr>,
negated: bool,
},
InSubquery {
expr: Box<Expr>,
subquery: Box<Query>,
negated: bool,
},
Between {
expr: Box<Expr>,
negated: bool,
low: Box<Expr>,
high: Box<Expr>,
},
Like {
expr: Box<Expr>,
negated: bool,
pattern: Box<Expr>,
},
ILike {
expr: Box<Expr>,
negated: bool,
pattern: Box<Expr>,
},
Regex {
expr: Box<Expr>,
negated: bool,
pattern: Box<Expr>,
case_sensitive: bool,
},
BinaryOp {
left: Box<Expr>,
op: BinaryOperator,
right: Box<Expr>,
},
UnaryOp {
op: UnaryOperator,
expr: Box<Expr>,
},
Nested(Box<Expr>),
Literal(Literal),
Value(Value),
TypedString {
data_type: DataType,
value: String,
},
Function(Box<Function>),
Aggregate(Box<Aggregate>),
Exists {
subquery: Box<Query>,
negated: bool,
},
Subquery(Box<Query>),
Case {
operand: Option<Box<Expr>>,
when_then: Vec<(Expr, Expr)>,
else_result: Option<Box<Expr>>,
},
ArrayIndex {
obj: Box<Expr>,
indexes: Vec<Expr>,
},
Interval {
expr: Box<Expr>,
leading_field: Option<DateTimeField>,
last_field: Option<DateTimeField>,
},
Array {
elem: Vec<Expr>,
},
}Variants§
Identifier(String)
CompoundIdentifier
IsNull(Box<Expr>)
IsNotNull(Box<Expr>)
InList
InSubquery
Between
Like
ILike
Regex
BinaryOp
UnaryOp
Nested(Box<Expr>)
Literal(Literal)
Value(Value)
TypedString
Function(Box<Function>)
Aggregate(Box<Aggregate>)
Exists
Subquery(Box<Query>)
Case
ArrayIndex
Interval
Array
Trait Implementations§
Source§impl<'de> Deserialize<'de> for Expr
impl<'de> Deserialize<'de> for Expr
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
impl Eq for Expr
impl StructuralPartialEq for Expr
Source§impl ToSqlUnquoted for Expr
impl ToSqlUnquoted for Expr
fn to_sql_unquoted(&self) -> String
Auto Trait Implementations§
impl Freeze for Expr
impl RefUnwindSafe for Expr
impl Send for Expr
impl Sync for Expr
impl Unpin for Expr
impl UnsafeUnpin for Expr
impl UnwindSafe for Expr
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
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