Bug #101122 | Default value expressions "(NOW())" AND "NOW()" behave differently | ||
---|---|---|---|
Submitted: | 11 Oct 2020 21:31 | Modified: | 16 Nov 2020 21:42 |
Reporter: | Moriyoshi Koizumi | Email Updates: | |
Status: | Not a Bug | Impact on me: | |
Category: | MySQL Server: Data Types | Severity: | S3 (Non-critical) |
Version: | 8.0.21 | OS: | Any |
Assigned to: | CPU Architecture: | Any |
[11 Oct 2020 21:31]
Moriyoshi Koizumi
[11 Oct 2020 21:34]
Moriyoshi Koizumi
The DDL was actually emitted by SQLAlchemy (a Python ORM) and there is no workaround to configure it to not do so except modifying the ORM engine, so I consider it to be rather serious.
[12 Oct 2020 13:32]
MySQL Verification Team
Hi Mr. Koisumi, Thank you for your bug report. However, this is not a bug. Our Reference Manual clearly states that this syntax can not be used. But, it could be possible to make this a feature request. That means, that syntax error is thrown on CREATE TABLE , ALTER TABLE and similar and not after. What do you say ??????
[13 Nov 2020 1:00]
Bugs System
No feedback was provided for this bug for over a month, so it is being suspended automatically. If you are able to provide the information that was originally requested, please do so and change the status of the bug back to "Open".
[16 Nov 2020 21:42]
Moriyoshi Koizumi
As far as I see in your manual, it clearly say column definitions accept any valid expressions. column_definition: { data_type [NOT NULL | NULL] [DEFAULT {literal | (expr)} ] ... https://dev.mysql.com/doc/refman/8.0/en/create-table.html Can you elaborate on what you were referring to ?
[16 Nov 2020 21:42]
Moriyoshi Koizumi
This is obviously a bug. Please reopen.
[17 Nov 2020 12:34]
MySQL Verification Team
Hi Mr. Koizumi, '0' is not a valid default for any DATE / TIME / DATETIME data type. Hence, this is not a bug.