MySQL: importing-export mysql table.
At the source database server, execute this terminal command:
mysqldump -u root -p [FromDatabaseName] [tableName] > [filePath.sql]
Then copy the output file("filePath.sql") to the destination database server and execute this command on the terminal:
mysql -u root -p [ToDatabaseName] < [filePath.sql]
If you want, you may also rename the exported table on the destination database:
mysql -u root -p
rename table tableName to newTableName;
mysqldump -u root -p [FromDatabaseName] [tableName] > [filePath.sql]
Then copy the output file("filePath.sql") to the destination database server and execute this command on the terminal:
mysql -u root -p [ToDatabaseName] < [filePath.sql]
If you want, you may also rename the exported table on the destination database:
mysql -u root -p
rename table tableName to newTableName;