From 2e8e6e581f47d178b7b14cee47c10ad6efcee9ca Mon Sep 17 00:00:00 2001 From: Aaron Patterson Date: Mon, 23 Aug 2010 14:27:16 -0700 Subject: we should mark sql strings as sql literals --- activerecord/lib/active_record/association_preload.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) 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], -- cgit v1.2.3