MySQL 5.7 Reference Manual
MySQL 5.7 Release Notes
MySQL Server does not support the SELECT ... INTO
TABLE
Sybase SQL extension. Instead, MySQL Server
supports the
INSERT INTO ...
SELECT
standard SQL syntax, which is basically the
same thing. See INSERT ... SELECT Statement. For example:
INSERT INTO tbl_temp2 (fld_id)
SELECT tbl_temp1.fld_order_id
FROM tbl_temp1 WHERE tbl_temp1.fld_order_id > 100;
Alternatively, you can use
SELECT ... INTO
OUTFILE
or
CREATE TABLE ...
SELECT
.
You can use SELECT ...
INTO
with user-defined variables. The same syntax
can also be used inside stored routines using cursors and
local variables. See SELECT ... INTO Statement.