On Tue, Oct 14, 2008 at 11:54 AM, Nate Wiger <[EMAIL PROTECTED]> wrote:
>> Actually, we're very close to having this working -- we'd just need to
>> tweak TimeWithZone#to_s(:db) to report the time relative to the system
>> local zone if config.active_record.default_timezone == :local.

Unless I am missing something here...

Wouldn't the time you store in the database be the timezone you set in
the config file?

If I set config.active_record_default_timezone == :local, then all the
records in the database should be saved in my local time.

Makes little difference with a timestamp with timezone, but all the
difference in the world on a record that is timestamp without,
especially when you are having to play good database citizen and share
the DB with other applications in other time zones that already save
everything in LA USA time because it is a 15 year old application /
convention :)

anyway, the setting in the config file should over ride any default
value that the adapter thinks IMHO.  This would be expected behaviour.
 Not convert on the fly and _always_ store UTC in the DB regardless of
any config setting.  This would cause serious problems for legacy DB
people I think.

Mikel

-- 
http://lindsaar.net/
Rails, RSpec and Life blog....

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Ruby 
on Rails: Core" group.
To post to this group, send email to rubyonrails-core@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/rubyonrails-core?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to