I'm a newbie with this so am having quite a bit of trouble. I've created a Drupal site in WAMP Server and am raedy to move the site to my hosting with Heart Internet.

I've copied C:/Wamp/www/mywebsite into a zip folder and uploaded/unzipped into my hosting space so the files are uploaded successfully.

I then went into phpMyAdmin on my computer and exported my database. I then created a blank database on my web hosting on the live server. this database username is c150-drupal and i generated a random password. I then clicked 'restore' on my new blank database and selected the database that I exported from WAMP. however I keep getting the error message below:

ERROR 1044 (420000) at line 22: access denied for user 'c150-drupal'@'%' to 'postcodedatabase'

I'm so confused how I should be exporting mysql databases in order to upload them to my webserver. Also is it acceptable to export a database from WAMP in order to use as a backup incase anything goes wrong so I could import the database back into WAMP?

Thank you,.

  • 1
    Have you changed your username and password in settings.php
    – 4life
    Jan 15, 2014 at 17:30

2 Answers 2


You should check your user privilege on your production server because you can't do this action.

This thread deals with your problem : https://stackoverflow.com/questions/8838777/error-1044-42000-access-denied-for-user-localhost-to-database-db


I take it you're using phpMyAdmin on the hosting server as well? make sure the DB names are the same for the new/empty one and the one you exported from - and if you manually changed the .sql file, make sure you changed the name in all places (CREATE and USE queries);

also check that the user has appropriate permissions for the new/empty DB - the hosting services often have it not in phpMyAdmin, but at the came place where you create DBs and users - look for something like "Add User To Database", and do exactly that - add the user to the DB with enough permissions to create/write

hope this helps

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.