diff options
author | Aaron Patterson <aaron.patterson@gmail.com> | 2010-09-28 15:32:12 -0700 |
---|---|---|
committer | Aaron Patterson <aaron.patterson@gmail.com> | 2010-09-28 15:32:12 -0700 |
commit | d0fb0d770f6253bbab75e32e9190c4e89b084f26 (patch) | |
tree | 53a8183463e67fa9b8e095278835cd15ef15af1d /activerecord | |
parent | cdfd013dd7953fc87038c73ecddbaa8cfe29a301 (diff) | |
download | rails-d0fb0d770f6253bbab75e32e9190c4e89b084f26.tar.gz rails-d0fb0d770f6253bbab75e32e9190c4e89b084f26.tar.bz2 rails-d0fb0d770f6253bbab75e32e9190c4e89b084f26.zip |
fisting the postgresql tests
Diffstat (limited to 'activerecord')
-rw-r--r-- | activerecord/lib/active_record/relation/calculations.rb | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/activerecord/lib/active_record/relation/calculations.rb b/activerecord/lib/active_record/relation/calculations.rb index 86b89c741d..0b3d1ed3ff 100644 --- a/activerecord/lib/active_record/relation/calculations.rb +++ b/activerecord/lib/active_record/relation/calculations.rb @@ -215,7 +215,8 @@ module ActiveRecord select_statement << "#{group_field} AS #{group_alias}" - relation = except(:group).select(select_statement).group(group) + relation = except(:group).group(group) + relation.select_values = select_statement calculated_data = @klass.connection.select_all(relation.to_sql) |