diff options
Diffstat (limited to 'lib/arel')
-rw-r--r-- | lib/arel/relations/relation.rb | 9 |
1 files changed, 2 insertions, 7 deletions
diff --git a/lib/arel/relations/relation.rb b/lib/arel/relations/relation.rb index 62656773dd..846594e7cd 100644 --- a/lib/arel/relations/relation.rb +++ b/lib/arel/relations/relation.rb @@ -115,8 +115,8 @@ module Arel "SELECT #{attributes.collect { |a| a.to_sql(Sql::SelectClause.new(self)) }.join(', ')}", "FROM #{table_sql(Sql::TableReference.new(self))}", (joins(Sql::TableReference.new(self)) unless joins.blank? ), - ("WHERE #{selects.collect { |s| s.to_sql(Sql::WhereClause.new(self)) }.join("\n\tAND ")}" unless selects.blank? ), - ("ORDER BY #{orders.collect { |o| o.to_sql(Sql::OrderClause.new(self)) }.join(', ')}" unless orders.blank? ), + ("WHERE #{selects.collect { |s| s.to_sql(Sql::WhereClause.new(self)) }.join("\n\tAND ")}" unless selects.blank? ), + ("ORDER BY #{orders.collect { |o| o.to_sql(Sql::OrderClause.new(self)) }.join(', ')}" unless orders.blank? ), ("GROUP BY #{groupings.collect(&:to_sql)}" unless groupings.blank? ), ("LIMIT #{taken}" unless taken.blank? ), ("OFFSET #{skipped}" unless skipped.blank? ) @@ -162,11 +162,6 @@ module Arel self end - # INVESTIGATE - def format(object) - object.to_sql(Sql::WhereCondition.new(self)) - end - def christener self end |