How to transfer my MySQL database to another computer?

dannail picture dannail · Mar 25, 2012 · Viewed 57.7k times · Source

I am using XAMPP package in my own desktop with Window 7 as OS.
That means I'm using MySQL DB and Apache server.

Now I would like to copy/migrate my whole MySQL DB to my friend's desktop, which is also with Window as OS, and also using XAMPP package.

Is there any way for me to do that?

Answer

A.Aleem11 picture A.Aleem11 · Dec 29, 2016

Copy database files from MySQL folder (under old xampp folder) except share,bin, and script folder see attached image to see which files need copy (only files with in green box) and replace all these database files in new installed xampp directory in MySQL folder.

Restart xampp start MySQL and open database and table to make sure its working.

Files to replace in green lines