Sha256: a96680c677f0e4cb661fcc902acb8b9433c9f819210b13143ea139b66ce7f17d

Contents?: true

Size: 221 Bytes

Versions: 13

Compression:

Stored size: 221 Bytes

Contents

module ActiveReporter
  module Aggregator
    class Sum < ActiveReporter::Aggregator::Base
      def function
        "SUM(#{expression})"
      end

      def default_value
        super || 0
      end
    end
  end
end

Version data entries

13 entries across 13 versions & 1 rubygems

Version Path
active_reporter-0.7.1 lib/active_reporter/aggregator/sum.rb
active_reporter-0.6.5 lib/active_reporter/aggregator/sum.rb
active_reporter-0.6.4 lib/active_reporter/aggregator/sum.rb
active_reporter-0.6.3 lib/active_reporter/aggregator/sum.rb
active_reporter-0.6.2 lib/active_reporter/aggregator/sum.rb
active_reporter-0.6.1 lib/active_reporter/aggregator/sum.rb
active_reporter-0.6.0 lib/active_reporter/aggregator/sum.rb
active_reporter-0.5.13 lib/active_reporter/aggregator/sum.rb
active_reporter-0.5.12 lib/active_reporter/aggregator/sum.rb
active_reporter-0.5.11 lib/active_reporter/aggregator/sum.rb
active_reporter-0.5.10 lib/active_reporter/aggregator/sum.rb
active_reporter-0.5.9 lib/active_reporter/aggregator/sum.rb
active_reporter-0.5.8 lib/active_reporter/aggregator/sum.rb