2016-03-07 48 views
0

得到錯誤這裏是我的查詢在MySQL查詢

Select * into my_db.employee 
    From my_db.persons ; 

我想將數據從一個表複製到另一個表,但得到的錯誤。

任何幫助將是有益的

感謝

+1

您需要發佈錯誤。儘可能讓人們幫助你。 – Carcigenicate

回答

0

在MySQL正確的語法是create table as:在SQL Server

create table my_db.employee as 
    Select * 
    From my_db.persons ; 

你的語法著作。

+0

這是查詢SELECT INTO –

+0

MySQL不支持SELECT INTO查詢嗎? –

+0

@KetanGupta。 。 。在MySQL中,'select into'用於寫入文件或設置用戶定義的變量,但不用於創建表。這就是'創建表'的功能。 –