[ 
https://issues.apache.org/jira/browse/AVRO-739?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13760576#comment-13760576
 ] 

Doug Cutting commented on AVRO-739:
-----------------------------------

> There are two types of interest [ ... ]

These seem like two different external representations of the same thing.  A 
time plus a timezone can be losslessly converted to a UTC time.  You do lose 
the original timezone, but dates and times are usually displayed in the 
timezone of the displayer, not where the time was originally noted.

Also note that SQL has five different variants 
(http://en.wikipedia.org/wiki/SQL#Date_and_time) which are interconvertable.  I 
suggest all of these should be converted to a single type in Avro.  Perhaps one 
could annotate the schema with resolution and/or timezone to improve fidelity, 
e.g., {"type":"Datetime", "resolution":"date", "timezone":"PST"}, but a long 
would always be written and used for comparison with other Datetime instances.

> How would we migrate from this klunky form to "type":"instant"?

We could simply treat instances of the klunky schema identically to 
"type":"instant".
                
> Add Date/Time data types
> ------------------------
>
>                 Key: AVRO-739
>                 URL: https://issues.apache.org/jira/browse/AVRO-739
>             Project: Avro
>          Issue Type: New Feature
>          Components: spec
>            Reporter: Jeff Hammerbacher
>         Attachments: AVRO-739.patch
>
>


--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

Reply via email to