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

Runkang He commented on CALCITE-5957:
-------------------------------------

I agree Julian's explanation, and then I think CALCITE-5678 is not intended to 
fully use strict ISO-8601 standard to replace the old way. So now we still use 
the old date parsing method. The plan to use strict ISO-8601 standard may need 
more discussion later. As [~zabetak] pointed out, people have different 
opinions on the topic, and I also pefer to use strict mode personally.

I think '900-01-01' is valid to keep consistent with other parts of date or 
time with leading zeros.

'2023-01-01 22:00:00.123.123' is invalid because the last '.123' is invalid as 
a time string. We need correct punctuations to define the valid date and time 
string, and should reject the wrong punctuations.

> Valid DATE '1945-2-2' is not accepted due to regression
> -------------------------------------------------------
>
>                 Key: CALCITE-5957
>                 URL: https://issues.apache.org/jira/browse/CALCITE-5957
>             Project: Calcite
>          Issue Type: Bug
>          Components: core
>    Affects Versions: 1.35.0
>            Reporter: Runkang He
>            Priority: Blocker
>             Fix For: avatica-1.24.0
>
>         Attachments: image-2023-08-27-19-09-33-284.png
>
>          Time Spent: 10m
>  Remaining Estimate: 0h
>
> DATE '1945-2-2' is a valid date. In CALCITE-5923 when we turn on the result 
> check of `testCastStringToDateTime`, we find that Calcite accepted DATE 
> '1945-2-2' before CALCITE-5678 but not afterwards, so this is a regression 
> that we need to fix.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

Reply via email to