There are times during migrations, database restores etc that you will need to export and import your MySQL database. Below shows you the commands required to achieved this.
Note : This article is meant as a reference point rather then a full blown article.
EXPORT
mysqldump -u root -p {database} > db.sql
IMPORT
mysql -u root -p -h 127.0.0.1 {database} < db.sql
Recent Comments