You can change the type of created field from datetime
to varchar(255)
, then you can set (update) all records that have the value "0000-00-00 00:00:00"
to NULL
.
Now, you can do your queries without error.
After you finished, you can alter the type of the field created to datetime
.