diff options
author | Aaron Patterson <aaron.patterson@gmail.com> | 2010-08-23 14:27:16 -0700 |
---|---|---|
committer | Aaron Patterson <aaron.patterson@gmail.com> | 2010-08-23 14:28:15 -0700 |
commit | 2e8e6e581f47d178b7b14cee47c10ad6efcee9ca (patch) | |
tree | aa4e86153f8b761ce2a78c5935308425057a7fb2 | |
parent | 5931a1dbd3d067d9d4cb33b0344a9a7931bb681b (diff) | |
download | rails-2e8e6e581f47d178b7b14cee47c10ad6efcee9ca.tar.gz rails-2e8e6e581f47d178b7b14cee47c10ad6efcee9ca.tar.bz2 rails-2e8e6e581f47d178b7b14cee47c10ad6efcee9ca.zip |
we should mark sql strings as sql literals
-rw-r--r-- | activerecord/lib/active_record/association_preload.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/activerecord/lib/active_record/association_preload.rb b/activerecord/lib/active_record/association_preload.rb index 4664f03ff3..63224377a3 100644 --- a/activerecord/lib/active_record/association_preload.rb +++ b/activerecord/lib/active_record/association_preload.rb @@ -370,7 +370,7 @@ module ActiveRecord conditions << append_conditions(reflection, preload_options) find_options = { - :select => preload_options[:select] || options[:select] || "#{table_name}.*", + :select => preload_options[:select] || options[:select] || Arel::SqlLiteral.new("#{table_name}.*"), :include => preload_options[:include] || options[:include], :conditions => [conditions, ids], :joins => options[:joins], |