View Full Version : Question on re-installing a SQL Database pls

04-10-2013, 04:12 PM
Hi my Wordpress blog is getting very good traffic and I am practicising with another server how to make a full SQL backup of the wordpress blog.

I installed wordpress and created the database. To test how to re-install I deleted the database and zipped up the wordpress and sql tables.

When I created the database again with the same credentials and uploaded the sql via the import function it gave me an error.

My question is - lets say your wordpress got hacked do you simply re-upload a PREVIOUS copy of SQL (pre-hack) rather than delete the database?

Hope that makes sense thanks for all help

04-12-2013, 03:02 PM
I use phpMyAdmin to import and export database info. If you do not drop the database your going to get an error saying something like "Can not create database because database 'name of db' exists."

I do make a copy of the suspect db incase... In a different location.

04-12-2013, 03:13 PM
Thanks for that - in fact, I worked it out and its actually very simple and easy - you just have to edit the wp-config.php in Wordpress to match the new DB settings. Obvious I know but that's experience for you....