Mysql table related operations
Create table
create table tt
Create table if not available
create table if not exists tt
Copy table structure
create table t2 like t1 create table t2 select * from t1 where 1 = 2
Copy table data
If the result is the same,
insert into t2 select * from t1
Only need to copy some Field,
insert into t2 (column1, column2, ...) select (column1, column2, ...) from t1
The above is the content of the related operations of the mysql table. For more related content, please pay attention to the PHP Chinese website (www.php.cn)!