Error 1146 when integrating a MySQL database in an already existing remote MySQL server

1

I have one remote server with MySQL databases running on it and I would like to move one database I have on my personal computer in this remote MySQL server to centralize everything.

Global configurations:

  • Personal Computer (origin): MySQL 5.7 and Ubuntu 16.04
  • Server (target): macOS El Capitan + MySQL 5.7

If I move only the database file to the new computer (using secure copy) I’m running into an error saying tables doesn’t exit but I’m still able to select the database name in the list:

 ERROR 1146 (42S02): Table ´database_name.table_name´ doesn´t exist

If I also move configurations files, I will erase existing configuration for currently running databases.

How can I merge MySQL configuration files to merge all those databases on the same device without loosing any data?

hackela

Posted 2017-09-12T19:07:45.503

Reputation: 33

Question was closed 2017-09-13T17:05:43.820

Answers

-1

You could try exporting using mysqldump

mysqldump -u username -ppassword databasename -c >my.sql

now copy the my.sql file over, pre-create the database and import the data.

cybernard

Posted 2017-09-12T19:07:45.503

Reputation: 11 200