大家好,又见面了,我是你们的朋友全栈君。
原文链接:http://www.fengyachao.com/archives/69
1.原字段没数据
alter table tb_test modify col integer;
2.原字段有数据
alter table tb_test add col_temp integer;
update tb_test set col_temp=col;
alter table tb_test drop column col;
alter table tb_test rename column col_temp to col;
发布者:全栈程序员-站长,转载请注明出处:https://javaforall.net/163912.html原文链接:https://javaforall.net