pub struct InOperatorLifter { /* private fields */ }
Expand description
Specialized lifter for IN operator expressions with function calls
Implementations§
Source§impl InOperatorLifter
impl InOperatorLifter
pub fn new() -> Self
Sourcepub fn needs_in_lifting(expr: &SqlExpression) -> bool
pub fn needs_in_lifting(expr: &SqlExpression) -> bool
Check if an IN expression needs lifting (has function call on left side)
Sourcepub fn lift_in_expressions(
&mut self,
stmt: &mut SelectStatement,
) -> Vec<LiftedInExpression>
pub fn lift_in_expressions( &mut self, stmt: &mut SelectStatement, ) -> Vec<LiftedInExpression>
Lift IN expressions with function calls
Sourcepub fn apply_lifted_to_select(
&self,
stmt: &mut SelectStatement,
lifted: &[LiftedInExpression],
)
pub fn apply_lifted_to_select( &self, stmt: &mut SelectStatement, lifted: &[LiftedInExpression], )
Apply lifted expressions to SELECT items
Sourcepub fn create_lifting_cte(
&self,
base_table: &str,
lifted: &[LiftedInExpression],
cte_name: String,
) -> CTE
pub fn create_lifting_cte( &self, base_table: &str, lifted: &[LiftedInExpression], cte_name: String, ) -> CTE
Create a CTE that includes the lifted expressions
Sourcepub fn rewrite_query(&mut self, stmt: &mut SelectStatement) -> bool
pub fn rewrite_query(&mut self, stmt: &mut SelectStatement) -> bool
Rewrite a query to lift IN expressions with function calls
Auto Trait Implementations§
impl Freeze for InOperatorLifter
impl RefUnwindSafe for InOperatorLifter
impl Send for InOperatorLifter
impl Sync for InOperatorLifter
impl Unpin for InOperatorLifter
impl UnwindSafe for InOperatorLifter
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> 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