I have a localhost (XAMPP) on an old pc. I need the MySQL database on my new mac with a localhost (MAMP). Issue is, pc doesn't have internet connection. Any way I can move the database over? Detailed instructions are highly welcomed as I am by no means a server expert. Thanks
closed as off topic by Zoredache, dmourati, rnxrx, Michael Hampton♦, Scott Pack Oct 8 '12 at 1:57
Questions on Server Fault are expected to relate to server, networking, or related infrastructure administration within the scope defined by the community. Consider editing the question or leaving comments for improvement if you believe the question can be reworded to fit within the scope. Read more about reopening questions here.If this question can be reworded to fit the rules in the help center, please edit the question.
You should be able to just use a USB Stick as suggested in the comments above. Just make sure to remove/modify the permissions on the DB file(s) first to avoid having issues with not being able to access the DB once it is moved over. That is a painful, painful, painful lesson if something goes wrong... experience talking.
XAMP should have phpmyadmin installed. If so, I would use it to create a backup / dump of the data base. Put that on your usb, move it to the mac, and again use phpmyadmin to first create a data base, then import your data.
You could also use mysqldump (at least on Linux from command line. Not sure about XAMP on windows):
mysqldump -u username -p database | gzip > database.sql.gz ( the pipe gzip is optional)
so say your db name is db_important and your db username is phil
mysqldump -u phil -p db_important | gzip > db_important.sql.gz
( when you run this you will be asked for your db password)
Or wihout gzip:
mysqldump -u phil -p db_important > db_important.sql
phpmyadmin should be easiest and safest route for you if your unfamiliar with mysql command line
these links may help: