Skip to content

Conversation

breunigs
Copy link

Asp er the MySQL documentation DATE and DATETIME only support ranges from
'1000-01-01 00:00:00' to '9999-12-31 23:59:59', and TIMESTAMP from
'1970-01-01 00:00:01.000000' to '2038-01-19 03:14:07.999999'. Values outside
those ranges are not guaranteed to work. Additionally it mentions that invalid
values are converted to their appropriate zero value.

The patch converts dates that lead to an exception right now to their zero
value. This is more lenient than what the ranges given in the documentation.
The behaviour set through zeroDateTimeBehavior applies to these zero values.

This fixes Bug#94872.

Asp er the MySQL documentation DATE and DATETIME only support ranges from
'1000-01-01 00:00:00' to '9999-12-31 23:59:59', and TIMESTAMP from
'1970-01-01 00:00:01.000000' to '2038-01-19 03:14:07.999999'. Values outside
those ranges are not guaranteed to work. Additionally it mentions that invalid
values are converted to their appropriate zero value.

The patch converts dates that lead to an exception right now to their zero
value. This is more lenient than what the ranges given in the documentation.
The behaviour set through zeroDateTimeBehavior applies to these zero values.

This fixes Bug#94872.
@mysql-oca-bot
Copy link

Hi, thank you for your contribution. Please confirm this code is submitted under the terms of the OCA (Oracle's Contribution Agreement) you have previously signed by cutting and pasting the following text as a comment:
"I confirm the code being submitted is offered under the terms of the OCA, and that I am authorized to contribute it."
Thanks

@breunigs
Copy link
Author

I confirm the code being submitted is offered under the terms of the OCA, and that I am authorized to contribute it.

@mysql-oca-bot
Copy link

Hi, thank you for your contribution. Your code has been assigned to an internal queue. Please follow
bug http://bugs.mysql.com/bug.php?id=95789 for updates.
Thanks

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants