[
https://issues.apache.org/jira/browse/HIVE-22241?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16938586#comment-16938586
]
Ádám Szita commented on HIVE-22241:
-----------------------------------
[~jcamachorodriguez] I think this change is doing something the other way
around.
For example
{code:java}
select to_proleptic_gregorian(CAST('1582-10-02' AS DATE));{code}
gives 1582-09-22. Which would mean that 1582-10-02 being a Julian date which it
is, corresponds to an earlier date in proleptic Gregorian, where in reality it
should be later one: 1582-10-12.
AFAIK 1582-10-04 was the last Julian date, a day followed by 1582-10-15 and
this latter is already a (true) Gregorian calendar day. So 1582-10-02
interpreted as Julian date, should be 3 days before 1582-10-15 (true)
Gregorian, making it a 1582-10-12 proleptic Gregorian date.
> Implement UDF to convert a date/timestamp from Gregorian-Julian hybrid
> calendar to proleptic Gregorian calendar
> ---------------------------------------------------------------------------------------------------------------
>
> Key: HIVE-22241
> URL: https://issues.apache.org/jira/browse/HIVE-22241
> Project: Hive
> Issue Type: Improvement
> Components: UDF
> Reporter: Jesus Camacho Rodriguez
> Assignee: Jesus Camacho Rodriguez
> Priority: Major
> Labels: pull-request-available
> Attachments: HIVE-22241.01.patch, HIVE-22241.patch
>
> Time Spent: 10m
> Remaining Estimate: 0h
>
> UDF that converts a date/timestamp from *Gregorian-Julian hybrid* calendar,
> i.e., calendar that supports both the Julian and Gregorian calendar systems
> with the support of a single discontinuity, which corresponds by default to
> the Gregorian date when the Gregorian calendar was instituted, to *proleptic
> Gregorian calendar* (ISO 8601 standard), which is produced by extending the
> Gregorian calendar backward to dates preceding its official introduction in
> 1582.
--
This message was sent by Atlassian Jira
(v8.3.4#803005)