title: Timestamp can't be saved - postgresql
body: <p>I have the below code snippet:</p>
  
  <pre><code>class Foo    
    include DataMapper::Resource
    property :id, Serial
    property :timestamp, DateTime
   end
  </code></pre>
  
  <p>I just want to convert the current time to ms:</p>
  
  <pre><code> class Time
     def to_ms
       (self.to_f * 1000.0).to_i
     end
   end
  
   def current_time
     time = Time.now
     return time.to_ms
    end
  
    time = current_time # =&gt; 1352633569151
  </code></pre>
  
  <p>but when I am going to save the Foo with above timestamp, then it can't be saved to the database and I'm not getting any error message.</p>
  
  <pre><code>foo = Foo.new
  foo.timestamp = time
  foo.save
  </code></pre>
  
  <p>Any idea?</p>