diff options
author | Aaron Patterson <aaron.patterson@gmail.com> | 2010-08-23 14:44:10 -0700 |
---|---|---|
committer | Aaron Patterson <aaron.patterson@gmail.com> | 2010-08-23 14:44:10 -0700 |
commit | c151df07acc06b06179c2dc6205db029ff9ce001 (patch) | |
tree | 24717fd5502ac9fa2634df8694e04aa800d3e287 /lib/arel/visitors | |
parent | 3bc3b145aedea216eb84e213bac1017c6090d42b (diff) | |
download | rails-c151df07acc06b06179c2dc6205db029ff9ce001.tar.gz rails-c151df07acc06b06179c2dc6205db029ff9ce001.tar.bz2 rails-c151df07acc06b06179c2dc6205db029ff9ce001.zip |
AND nodes are supported
Diffstat (limited to 'lib/arel/visitors')
-rw-r--r-- | lib/arel/visitors/to_sql.rb | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/lib/arel/visitors/to_sql.rb b/lib/arel/visitors/to_sql.rb index 6576d82c41..8136039040 100644 --- a/lib/arel/visitors/to_sql.rb +++ b/lib/arel/visitors/to_sql.rb @@ -86,6 +86,10 @@ module Arel "#{visit o.left} IN (#{o.right.map { |x| visit x }.join ', '})" end + def visit_Arel_Nodes_And o + "#{visit o.left} AND #{visit o.right}" + end + def visit_Arel_Nodes_Or o "#{visit o.left} OR #{visit o.right}" end |