Method: Influxer::TimeQuery#past
- Defined in:
- lib/influxer/metrics/relation/time_query.rb
#past(val) ⇒ Object
51 52 53 54 55 56 57 58 59 60 |
# File 'lib/influxer/metrics/relation/time_query.rb', line 51 def past(val) case val when Symbol where("time > now() - #{TIME_ALIASES[val] || ('1' + val.to_s)}") when String where("time > now() - #{val}") else where("time > now() - #{val.to_i}s") end end |