aboutsummaryrefslogtreecommitdiffstats
path: root/lib/arel/engines/sql
diff options
context:
space:
mode:
authorErnie Miller <ernie@metautonomo.us>2010-03-30 15:32:39 -0400
committerErnie Miller <ernie@metautonomo.us>2010-05-07 13:07:21 -0400
commit0433b054eebd5a53ff6c5f35383a6c0aed0015b2 (patch)
treeed07230cd0f1e033138f89e103bb2ce4cb6d6f7a /lib/arel/engines/sql
parent0afcfa27c9f386ca7c190cd1f66db1cdd9971f3b (diff)
downloadrails-0433b054eebd5a53ff6c5f35383a6c0aed0015b2.tar.gz
rails-0433b054eebd5a53ff6c5f35383a6c0aed0015b2.tar.bz2
rails-0433b054eebd5a53ff6c5f35383a6c0aed0015b2.zip
Tests for notmatches and notin, and fixes for issues found in tests
Diffstat (limited to 'lib/arel/engines/sql')
-rw-r--r--lib/arel/engines/sql/predicates.rb6
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/arel/engines/sql/predicates.rb b/lib/arel/engines/sql/predicates.rb
index 29bc74c605..b459168620 100644
--- a/lib/arel/engines/sql/predicates.rb
+++ b/lib/arel/engines/sql/predicates.rb
@@ -30,11 +30,11 @@ module Arel
def predicate_sql; "AND" end
end
- class GroupedPredicate < Grouped
+ class GroupedPredicate < Polyadic
def to_sql(formatter = nil)
"(" +
- operands2.inject([]) { |predicates, operand|
- predicates << operator.new(operand1, operand).to_sql
+ additional_operands.inject([]) { |predicates, operand|
+ predicates << operator.new(operand1, operand).to_sql(formatter)
}.join(" #{predicate_sql} ") +
")"
end