diff options
author | Emilio Tagua <miloops@gmail.com> | 2009-05-28 18:08:48 -0300 |
---|---|---|
committer | Emilio Tagua <miloops@gmail.com> | 2009-05-28 18:08:48 -0300 |
commit | 054b0103a8a833e643c954fb31b9a5d88e29968e (patch) | |
tree | 107766ff3a7b07e43e72695125599e6844fdca15 /lib/arel/engines | |
parent | c9bbea6115be520dbd47bd30108c5622289deb26 (diff) | |
download | rails-054b0103a8a833e643c954fb31b9a5d88e29968e.tar.gz rails-054b0103a8a833e643c954fb31b9a5d88e29968e.tar.bz2 rails-054b0103a8a833e643c954fb31b9a5d88e29968e.zip |
This should be performed by the engine, if it does not exists, then create SQLLiteral not Attribute.
Diffstat (limited to 'lib/arel/engines')
-rw-r--r-- | lib/arel/engines/sql/formatters.rb | 1 |
1 files changed, 0 insertions, 1 deletions
diff --git a/lib/arel/engines/sql/formatters.rb b/lib/arel/engines/sql/formatters.rb index ae80feb18e..22935ebff1 100644 --- a/lib/arel/engines/sql/formatters.rb +++ b/lib/arel/engines/sql/formatters.rb @@ -13,7 +13,6 @@ module Arel class SelectClause < Formatter def attribute(attribute) - # FIXME this should check that the column exists "#{quote_table_name(name_for(attribute.original_relation))}.#{quote_column_name(attribute.name)}" + (attribute.alias ? " AS #{quote(attribute.alias.to_s)}" : "") end |