Home > Database > Mysql Tutorial > MySQL使用查询结果创建表_MySQL

MySQL使用查询结果创建表_MySQL

WBOY
Release: 2016-06-01 13:45:02
Original
1741 people have browsed it

bitsCN.com

MYSQL不支持:
Select * Into new_table_name from old_table_name;
替代方法:
1
Create table new_table_name (Select * from old_table_name);
select * into new_table_name from old_table_name;
2
SELECT *  INTO OUTFILE 'a.txt' FROM table_name;
 LOAD DATA INFILE '/database/mysql/a.txt' INTO TABLE new_table_name;
 

作者“ylqmf的专栏”

bitsCN.com
Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template