Mysql瞎乱记1
来自三线的随记
时间戳转化为日期
FROM_UNIXTIME(column_name)
FROM_UNIXTIME(column_name, '%Y %D %M %h:%i:%s')
例如:'%Y %D %M %h:%i:%s %x'
日期格式转化为时间戳
UNIX_TIMESTAMP('2017-07-07 15:58:25')
ALTER TABLE `members` CHANGE `no` `no2` VARCHAR(4) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL;
alter table `table_name` add column `column_name` column_type {first|after ***}
alter table `table_name` change column `column_name` column_type {first|after ***}
alter table `table_name` change `column_name` column_type {first|after ***}
alter table `table_name` modify `column_name` column_type
alter table `table_name` modify column `column_name` column_type