aboutsummaryrefslogtreecommitdiffstats
path: root/lib/arel/engines/sql/extensions/range.rb
blob: 25bf1d01daaf0ec31c7022b6536ae962990380fa (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
module Arel
  module Sql
    module RangeExtensions
      def to_sql(formatter = nil)
        formatter.range self.begin, self.end
      end

      def inclusion_predicate_sql
        "BETWEEN"
      end
      
      Range.send(:include, self)
    end
  end
end