class

Marten::DB::Query::SQL::Join

Inherits Reference / Object

Represents an SQL join used in the context of a specific query.

SQL joins are managed as a tree, which means that each join can be associated with a list of underlying children joins (for the joins following the considered relationship). SQL joins are "flattened" when the raw SQL queries are generated.

Constructors

new(id : Int32, type : JoinType, from_model : Model.class, from_common_field : Field::Base, reverse_relation : ReverseRelation | Nil, to_model : Model.class, to_common_field : Field::Base, selected : Bool, table_alias_prefix : String = "t", children : Array(Marten::DB::Query::SQL::Join) = [] of self)
Source

Instance methods

add_child(child : self) : Nil
Source
children
Source
clone
Source
column_name(name) : String
Source
columns
Source
from_common_field
Source
from_model
Source
parent
Source
replace_table_alias_prefix(new_table_alias_prefix : String) : Hash(String, String)
Source
reverse_relation
Source
selected?
Source
table_alias
Source
table_alias_prefix
Source
to_a
Source
to_common_field
Source
to_model
Source
to_sql
Source
type
Source