From: Hunter Walker Date: 2006-09-22T12:53:21+09:00 Subject: Re: converting a number to a date WATANABE Hirofumi wrote: > Hi, > > Hunter Walker writes: > >> My XML request returned a date field as a "string" with the value of >> 1158364800000 >> Does Ruby have a function to turn this into a date? > > % ruby -e 'p Time.at("1158364800000".to_i / 1000.0).utc' > Sat, Sep 16 2006 00:00:00 +0000 This helps a lot. Thank you! Now we'll see if I can do some math with it. -- Posted via http://www.ruby-forum.com/.