From 4ef7ee8f35fdefd6eeef102f46497295a7b5d858 Mon Sep 17 00:00:00 2001 From: Aaron Patterson Date: Tue, 7 Sep 2010 11:02:38 -0700 Subject: doing sql literal conversion --- lib/arel/select_manager.rb | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'lib') diff --git a/lib/arel/select_manager.rb b/lib/arel/select_manager.rb index e362f369e7..c8cd37b9fa 100644 --- a/lib/arel/select_manager.rb +++ b/lib/arel/select_manager.rb @@ -19,7 +19,11 @@ module Arel end def project *projections - @ctx.projections.concat projections + # FIXME: converting these to SQLLiterals is probably not good, but + # rails tests require it. + @ctx.projections.concat projections.map { |x| + String == x.class ? SqlLiteral.new(x) : x + } self end -- cgit v1.2.3