create table ceshi(cid int); -- 第二列
alter table ceshi add num int first; -- 添加在第一列,第一列
-- alter table ceshi add quantity int last; -- 错误写法
alter table ceshi add quantity int after cid; -- 在cid后面添加,为第三列
-- 添加最后一列
alter table ceshi add last int after quantity; -- 第四列
在MySQL中添加字段列(first和last)的用法
最新推荐文章于 2023-10-28 22:55:12 发布