1.更改Float字段类型to Decimal
ALTER TABLE 表名 MODIFY 字段名 decimal(10,2) not null default '0';
如:
ALTER TABLE invoice MODIFY TotalMoney decimal(10,2) not null default '0';
2.添加字段
alter table 表名 add 字段名 字段类型 not null ;
如:
alter table teacher add TypeMark varchar(50) null default '';
mysql更改表字段类型
最新推荐文章于 2025-01-10 22:12:51 发布