diff options
author | Aaron Patterson <aaron.patterson@gmail.com> | 2010-12-06 20:26:15 -0800 |
---|---|---|
committer | Aaron Patterson <aaron.patterson@gmail.com> | 2010-12-06 20:26:15 -0800 |
commit | ee65dd6e0e5c79fa2d79944dbc541380f4b221d4 (patch) | |
tree | 9d83f4d5ec754826a7361d39b7b7d22efc0009f3 /lib/arel/visitors/mysql.rb | |
parent | 13d22766902af1d6f709b85a73e089b7afbb9dbf (diff) | |
parent | 4018b5d66a810a34273d4b198688896f6f7459f3 (diff) | |
download | rails-ee65dd6e0e5c79fa2d79944dbc541380f4b221d4.tar.gz rails-ee65dd6e0e5c79fa2d79944dbc541380f4b221d4.tar.bz2 rails-ee65dd6e0e5c79fa2d79944dbc541380f4b221d4.zip |
Merge branch '2-0-stable'
* 2-0-stable:
quoting limit nodes
Make "not" apply to the whole sub-expression when generating sql.
Diffstat (limited to 'lib/arel/visitors/mysql.rb')
-rw-r--r-- | lib/arel/visitors/mysql.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/arel/visitors/mysql.rb b/lib/arel/visitors/mysql.rb index 143b4d36f4..ace8fb0979 100644 --- a/lib/arel/visitors/mysql.rb +++ b/lib/arel/visitors/mysql.rb @@ -25,7 +25,7 @@ module Arel ("SET #{o.values.map { |value| visit value }.join ', '}" unless o.values.empty?), ("WHERE #{o.wheres.map { |x| visit x }.join ' AND '}" unless o.wheres.empty?), ("ORDER BY #{o.orders.map { |x| visit x }.join(', ')}" unless o.orders.empty?), - ("LIMIT #{o.limit}" if o.limit), + ("LIMIT #{visit o.limit}" if o.limit), ].compact.join ' ' end |