I want to copy a table from one database to another. Both the tables are on the same server but in different databases. I can see the both from the phpMyAdmin of the same server. I tried to run the following SQL command:
SELECT * INTO first_db.table_name FROM second_db.table_name
I replace first_db
, table_name
and second_db
with my actual database and table names. Unfortunately, running these queries gives me the following error:
Undeclared variable: first_db
All the database and table names actually exist.
Thanks.