I have a column of type int(11) in MySQL. I want to set default value to
timestampdiff(second,'2000-01-01 00:00:01',current_timestamp())
Right now I'm getting this error:
Operation failed: There was an error while applying the SQL script to the database.
Executing:
ALTER TABLE DB_NAME
.TABLE_NAME
CHANGE COLUMN time
time
INT(11) NULL DEFAULT 'timestampdiff(second,\'2000-01-01 00:00:01\',current_timestamp())' ;
ERROR 1067: Invalid default value for 'time'
SQL Statement:
ALTER TABLE DB_NAME
.TABLE_NAME
CHANGE COLUMN time
time
INT(11) NULL DEFAULT 'timestampdiff(second,\'2000-01-01 00:00:01\',current_timestamp())'