title: What is the best way to calculate difference between TIMESTAMP values in Ruby on Rails
body: <p>What is the best way to achieve the following behavior in Ruby on Rails 4.1.4?</p>
  
  <p>I have a table in DB with a column that contains TIMESTAMP values. I need to iterate over all records in this table and do some actions if the difference between TIMESTAMP value in this column and current time greater  than some amount of months or days.</p>
  
  <p>What is the best practice to do it? Convert TIMESTAMP value to the Unix time or use some class that handles dates by itself?</p>
  
  <p>Thanks in advance.</p>