mysql把一个表直接拷贝到一个新的表
一:在新表已经建立好的情况下
1,拷贝所有的字段
insert into new_table select * from old_table
2,拷贝部分字段表
insert into new_table(id,name,sex) select id,name,sex from old_table
3,拷贝部分的行
insert into new_table select * from old_table where id="1"
4,拷贝部分的行和字段
insert into new_..
原创
2021-06-30 14:18:16 ·
278 阅读 ·
0 评论