pub struct LateralJoin {
pub subquery: String,
pub alias: String,
pub join_type: LateralJoinType,
pub condition: Option<String>,
}Expand description
A LATERAL join specification.
Fields§
§subquery: StringThe subquery or function call.
alias: StringAlias for the lateral result.
join_type: LateralJoinTypeJoin type.
condition: Option<String>Optional ON condition (for LEFT LATERAL).
Implementations§
Source§impl LateralJoin
impl LateralJoin
Sourcepub fn new(
subquery: impl Into<String>,
alias: impl Into<String>,
) -> LateralJoinBuilder
pub fn new( subquery: impl Into<String>, alias: impl Into<String>, ) -> LateralJoinBuilder
Create a new LATERAL join.
Sourcepub fn to_postgres_sql(&self) -> String
pub fn to_postgres_sql(&self) -> String
Generate PostgreSQL LATERAL join.
Sourcepub fn to_mysql_sql(&self) -> String
pub fn to_mysql_sql(&self) -> String
Generate MySQL LATERAL join.
Sourcepub fn to_mssql_sql(&self) -> String
pub fn to_mssql_sql(&self) -> String
Generate MSSQL APPLY join.
Sourcepub fn to_sql(&self, db_type: DatabaseType) -> QueryResult<String>
pub fn to_sql(&self, db_type: DatabaseType) -> QueryResult<String>
Generate SQL for database type.
Trait Implementations§
Source§impl Clone for LateralJoin
impl Clone for LateralJoin
Source§fn clone(&self) -> LateralJoin
fn clone(&self) -> LateralJoin
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for LateralJoin
impl Debug for LateralJoin
Source§impl<'de> Deserialize<'de> for LateralJoin
impl<'de> Deserialize<'de> for LateralJoin
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
Source§impl PartialEq for LateralJoin
impl PartialEq for LateralJoin
Source§impl Serialize for LateralJoin
impl Serialize for LateralJoin
impl Eq for LateralJoin
impl StructuralPartialEq for LateralJoin
Auto Trait Implementations§
impl Freeze for LateralJoin
impl RefUnwindSafe for LateralJoin
impl Send for LateralJoin
impl Sync for LateralJoin
impl Unpin for LateralJoin
impl UnwindSafe for LateralJoin
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