class Orb::Query

Defined in:

query.cr
query/combine_clause.cr
query/delete.cr
query/distinct.cr
query/fragment.cr
query/from.cr
query/group_by.cr
query/helpers.cr
query/insert.cr
query/join.cr
query/limit.cr
query/multi_insert.cr
query/offset.cr
query/order_by.cr
query/result.cr
query/select.cr
query/select_distinct.cr
query/update.cr
query/where.cr

Constant Summary

CLAUSE_PRIORITY = {MultiInsert => 1, Insert => 1, Delete => 1, Update => 1, Select => 1, Distinct => 1, SelectDistinct => 1, From => 2, OrderBy => 3, Join => 4, Where => 5, GroupBy => 6, Limit => 7, Offset => 8}

Instance Method Summary

Instance Method Detail

def commit #

[View source]
def count : Int64 #

[View source]
def cross_join(table, columns) #

[View source]
def delete(table) #

[View source]
def distinct(*columns) #

[View source]
def from(table) #

[View source]
def full_join(table, columns) #

[View source]
def group_by(*columns) #

[View source]
def inner_join(table, columns) #

[View source]
def insert(table, values) #

[View source]
def insert(relation : Orb::Relation) #

[View source]
def join(table, columns) #

[View source]
def left_join(table, columns) #

[View source]
def limit(value) #

[View source]
def map_to(klass : Nil) #

[View source]
def multi_insert(table, values) #

[View source]
def multi_insert(relations : Array(Orb::Relation)) #

[View source]
def offset(value) #

[View source]
def or_where(column, operator, value) #

[View source]
def or_where(column, value) #

[View source]
def or_where(fragment : Fragment) #

[View source]
def or_where(**conditions) #

[View source]
def order_by(col : String | Symbol) #

[View source]
def order_by(order_by : Array(Tuple(String, String))) #

[View source]
def right_join(table, columns) #

[View source]
def select(fragment : Fragment) #

[View source]
def select(columns : Array(String)) #

[View source]
def select(klass : Orb::Relation.class) #

[View source]
def select(*columns) #

[View source]
def to_a #

[View source]
def to_result #

[View source]
def update(table, values) #

[View source]
def update(relation : Orb::Relation) #

[View source]
def where(column, operator, value) #

[View source]
def where(column, value) #

[View source]
def where(fragment : Fragment) #

[View source]
def where(**conditions) #

[View source]