Lakshya Goyal Lakshya Goyal - 2 months ago 5x
MySQL Question

How to restore database in MySQL/phpMyAdmin?

I was using the MAMP program to host my database locally on my laptop. I had a problem so I had to reinstall the MAMP software. Before I did that though, I copied my entire MAMP folder from my C drive to my desktop. Now that I have MAMP installed, I opened the startpage and then went to phpMyAdmin.

I want to know how I can restore my database? When I opened phpMyAdmin after reinstallation, I could see the database and the name of the tables. But when I click on the tables, it says the table doesn't exist. When I tried importing the table, there was an error and it didn't work. Here is a screenshot of the error:

MySQL Error

The copied database is in this location:

. In the
folder, there are the 3 tables which I had which have the
file extension. and then 1 file called
. How can I restore the tables to my database?

Thanks in advance


Here is a solution. It works very well.

You just need to copy the ib_LogFiles and the ibData file and it should all be fixed!