mysql - Current Date automated field -
hi trying create field within mysql table stores date on record entered.
i doing using next trigger:
create definer=`root`@`localhost` trigger `radia`.`orderstable_before_insert` before insert on `orderstable` each row begin set new.date = current_timestamp;
this gives me sql syntax error.
furthermore have tried set default value of column current_timestamp returns date plus time. want date show up. how can go achieving this?
mysql date
No comments:
Post a Comment