Closed gorkunov closed 9 years ago
No particular reason, I think we just didn't consider timezone. Please feel free to submit a pull request to convert to string serialization with timezone.
This is tough. In part because you want to serialize time as strings to keep timezone info, but then you've got to write some logic to do the scope comparators for >
, <
and eq
. Casting the string to a time with zone in PG might be a stretch. I'm all for it, but I don't think it will be easy.
After some internal discussion, it seems likely that you'd be better off storing UTC time only, and if you absolutely need the timezone you should probably store it as a separate column. You could even override the setter and have that store the timezone separately for you rather seamlessly.
Could you explain why time is serialized as integer not as string? There is no place where timezone can be stored with time. With string serialization we can keep timezone with time/date in database.