📅  最后修改于: 2022-03-11 14:58:24.746000             🧑  作者: Mango
if you generated the script from the MySQL workbench.
The following line is generated
SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='TRADITIONAL,ALLOW_INVALID_DATES';
Remove TRADITIONAL from the SQL_MODE, and then the script should work fine
Else, you could set the SQL_MODE as Allow Invalid Dates
SET SQL_MODE='ALLOW_INVALID_DATES';
reference :
https://stackoverflow.com/questions/9192027/invalid-default-value-for-create-date-timestamp-field