Can't select database (3 posts)

  1. invadergii
    Posted 8 years ago #

    I created a database and user account just now to install WordPress on my domain. It didn't have any problem with the user account, but it doesn't seem to be able to find the database. Anyone know of a way to fix this? My domain is through bluehost if that helps anyone. Here's the text of the error message:

    Can’t select database

    We were able to connect to the database server (which means your username and password is okay) but not able to select the eriknels_blog database.

    Are you sure it exists?
    On some systems the name of your database is prefixed with your username, so it would be like username_wordpress. Could that be the problem?
    If you don't know how to setup a database you should contact your host. If all else fails you may find help at the WordPress Support Forums.

  2. MichaelH
    Posted 8 years ago #

    Something is probably wrong in your wp-config.php.

    The DB_HOST should be localhost.

    Make sure there are no extra spaces in your definitions.

    define('DB_NAME', 'eriknels_blog ');
    define('DB_NAME', ' eriknels_blog');

    are both wrong because there is an extra space between the ' marks in both examples.

  3. Lynn
    Posted 8 years ago #

    Even with everything correct, no spaces, proper DB names, etc, upgrading WordPress ends in the "Can’t select database" error as invadergii describes.

Topic Closed

This topic has been closed to new replies.

About this Topic