module StaticRecord::QueryInterface::SearchModifiers
Contains search modifiers
Private Instance Methods
count()
click to toggle source
# File lib/static_record/models/query_interface/search_modifiers.rb, line 29 def count @columns = 'COUNT(*)' exec_request(:integer) end
joins(joint)
click to toggle source
# File lib/static_record/models/query_interface/search_modifiers.rb, line 8 def joins(joint) joint = joint.store unless [String, Symbol].include?(joint.class) @joins_clauses << joint self end
limit(amount)
click to toggle source
# File lib/static_record/models/query_interface/search_modifiers.rb, line 14 def limit(amount) @sql_limit = amount self end
offset(amount)
click to toggle source
# File lib/static_record/models/query_interface/search_modifiers.rb, line 19 def offset(amount) @sql_offset = amount self end
order(ord)
click to toggle source
# File lib/static_record/models/query_interface/search_modifiers.rb, line 24 def order(ord) @order_by << ord self end