I want to mofidy a TIMESTAMP column to take the CURRENT_TIMESTAMP as default value, and the CURRENT_TIMESTAMP when I modify it.
this is the script I tried :
ALTER TABLE annonce MODIFY COLUMN date_modif TIMESTAMP ON UPDATE CURRENT_TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP;
but I'm getting this error message :
1293 - Incorrect table definition; there can be only one TIMESTAMP column with CURRENT_TIMESTAMP in DEFAULT or ON UPDATE clause
I have also another column (date_crea) which has CURRENT_TIMESTAMP as the default value.
Is that means that I can only use the value CURRENT_TIMESTAMP in one column ??
if it's how can I solve that ?