What this means is you have a required date. Let’s say this is to ENFORCE that date is there and valid (without a default value obviously).Now, what you can expect, is that you cannot force the column to take a default value…it must be specified, so this is what you’d expect to see:

….So, I’ve specified that it cannot be NULL, but because datetime doesn’t actually have a NULL datatype, it accepts the NULL datetime of ’0000-00-00 00:00:00′. This is completely illogical. What’s worse, I specified NOT NULL, yet wrote an update to set date=NULL, and it passed. According to the MySQL 5 page, it’s because:

1

Illegal DATETIME, DATE, or TIMESTAMP values are converted to the “zero” value of the appropriate type ('0000-00-00 00:00:00' or '0000-00-00').

That’s fine and dandy, but the MySQL is ignoring the fact that I set date=NULL where the schema shouldn’t allow it.