1.复制表结构和表数据

create table table_new as select * from table_old

2.复制表结构

create table table_new as select * from table_old where 1<>1

3.复制表的指定字段

create table table_new as select o.column1,o.column2 from table_old o where 1<>1

4.复制表的指定字段的数据

create table table_new as select o.column1,o.column2 from table_old

简单描述,作为新手入门,写下来留以后技术回顾之用~

05-11 22:18