Bug #21797 | Can`t insert or update fields datetime setting null with null | ||
---|---|---|---|
Submitted: | 23 Aug 2006 16:53 | Modified: | 23 Sep 2006 18:06 |
Reporter: | Alejandro Ferreira | Email Updates: | |
Status: | No Feedback | Impact on me: | |
Category: | MySQL Server | Severity: | S3 (Non-critical) |
Version: | 5.0 | OS: | Windows (XP) |
Assigned to: | Assigned Account | CPU Architecture: | Any |
Tags: | datetime, insert, null |
[23 Aug 2006 16:53]
Alejandro Ferreira
[23 Aug 2006 18:06]
MySQL Verification Team
Thank you for the bug report. Please read: http://dev.mysql.com/doc/refman/5.0/en/server-sql-mode.html and verify which sql_mode you have configured. mysql> desc MyTable\G *************************** 1. row *************************** Field: date_up Type: date Null: YES Key: Default: 0000-00-00 Extra: *************************** 2. row *************************** Field: date_now Type: datetime Null: YES Key: Default: 0000-00-00 00:00:00 Extra: 2 rows in set (0.01 sec) mysql> insert into MyTable values('',''); Query OK, 1 row affected, 2 warnings (0.00 sec) mysql> show warnings; +---------+------+------------------------------------------------------------+ | Level | Code | Message | +---------+------+------------------------------------------------------------+ | Warning | 1265 | Data truncated for column 'date_up' at row 1 | | Warning | 1264 | Out of range value adjusted for column 'date_now' at row 1 | +---------+------+------------------------------------------------------------+ 2 rows in set (0.00 sec) mysql> select * from MyTable; +------------+---------------------+ | date_up | date_now | +------------+---------------------+ | 0000-00-00 | 0000-00-00 00:00:00 | +------------+---------------------+ 1 row in set (0.00 sec)
[23 Sep 2006 23: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".