Bug #102639 | weekday of year zero is wrong | ||
---|---|---|---|
Submitted: | 18 Feb 2021 9:55 | Modified: | 19 Feb 2021 6:03 |
Reporter: | jiangtao guo | Email Updates: | |
Status: | Unsupported | Impact on me: | |
Category: | MySQL Server | Severity: | S3 (Non-critical) |
Version: | OS: | Any | |
Assigned to: | CPU Architecture: | Any |
[18 Feb 2021 9:55]
jiangtao guo
[18 Feb 2021 14:48]
MySQL Verification Team
Hi Mr. guo, Thank you for your bug report. However, a result of any function on any date in the year 0 AD (or BC) is irrelevant. Simply, year 0 never occurred. Humanity has simply jumped from year 1 BC to year 1 AD. Unsupported.
[19 Feb 2021 6:03]
jiangtao guo
Thanks for your reply. In this(https://bugs.mysql.com/bug.php?id=25301) buf fix, I guess MySQL trys to follow the ISO standard, which support year zero(year ranges [0000, 9999]). Is that correct? Otherwise, maybe should clearly tell the user that MySQL does not support 0 years.
[19 Feb 2021 13:18]
MySQL Verification Team
Hi Mr. guo, Actually, there is sufficient info about zeroth year in our Manual. Specifically, look after all descriptions related to the INVALID_DATE category.
[20 Feb 2021 12:25]
Roy Lyseng
We sort-of support the year zero, although the official supported range of years is 1000 to 9999. Standard SQL supports the range 1 to 9999. However, I am not surprised that calculation involving dates from year zero is wrong, and it should also be questioned whether we should continue supporting adding dates with year zero. The zero date 0000-00-00 is a different issue. In the ISO standard, year zero is the same as 1 BC, so it would still be possible to support it, although the practical use is questionable.