From: Kirk Haines Date: 2005-12-04T09:42:12+09:00 Subject: Re: Help converting DateTime from UTC On Saturday 03 December 2005 5:03 pm, Geary Eppley wrote: > I trying to convert a parsed time of "2005-12-01T18:00:00Z" to the local > equivalent. > > I'm current in -800 (PST) and so and doing the following: > DateTime.parse("2005-12-01T18:00:00Z").new_offset(-8.0/24) > > What I get is very close, but not what I would expect: > 2005-12-01T09:59:59-0800 DateTime.parse("2005-12-01T18:00:00Z").new_offset(Rational(-8,24)) Kirk Haines