From 0cba6cde9958969933da79626d00464f7d07b22f Mon Sep 17 00:00:00 2001 From: Nick Kallen Date: Sat, 12 Jan 2008 20:34:18 -0800 Subject: bug with aggregation to_Sql --- lib/active_relation/primitives/aggregation.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'lib/active_relation/primitives') diff --git a/lib/active_relation/primitives/aggregation.rb b/lib/active_relation/primitives/aggregation.rb index 20fdcf46c5..a3c7747165 100644 --- a/lib/active_relation/primitives/aggregation.rb +++ b/lib/active_relation/primitives/aggregation.rb @@ -10,7 +10,7 @@ module ActiveRelation end def to_sql(options = {}) - "#{function_sql}(@attribute.to_sql)" + "#{function_sql}(#{@attribute.to_sql})" end def ==(other) -- cgit v1.2.3