为表增加字段的方法:
alter table 表名 add 字段 类型
修改原字段名
ALTER TABLE 表名 RENAME COLUMN 字段名 TO 字段名1;
修改字段类型的方法:
alter table 表名 modify 字段名类型
把表非空的字段设置为可空:
alter table 表名 alter 非空字段名 drop not null
为表增加字段的方法:
alter table 表名 add 字段 类型
修改原字段名
ALTER TABLE 表名 RENAME COLUMN 字段名 TO 字段名1;
修改字段类型的方法:
alter table 表名 modify 字段名类型
把表非空的字段设置为可空:
alter table 表名 alter 非空字段名 drop not null