skip to Main Content

I’m working on localhost doing some pages with wordpress. Yesterday I’ve finished to work with some pages, and then I turn off my pc. Today when I turned it on and I’ve tried to reach some pages (after have turned theApache and Mysql services on) wordpress say i need to install the framework again.

This is the 1st error i get:
error

Well I just put the same name etc etc… and the next error is this :

WordPress database error: [Table 'wp_users' already exists]
CREATE TABLE wp_users ( ID bigint(20) unsigned NOT NULL auto_increment, user_login varchar(60) NOT NULL default '', user_pass varchar(255) NOT NULL default '', user_nicename varchar(50) NOT NULL default '', user_email varchar(100) NOT NULL default '', user_url varchar(100) NOT NULL default '', user_registered datetime NOT NULL default '0000-00-00 00:00:00', user_activation_key varchar(255) NOT NULL default '', user_status int(11) NOT NULL default '0', display_name varchar(250) NOT NULL default '', PRIMARY KEY (ID), KEY user_login_key (user_login), KEY user_nicename (user_nicename), KEY user_email (user_email) ) DEFAULT CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci

WordPress database error: [Table 'wp_usermeta' already exists]
CREATE TABLE wp_usermeta ( umeta_id bigint(20) unsigned NOT NULL auto_increment, user_id bigint(20) unsigned NOT NULL default '0', meta_key varchar(255) default NULL, meta_value longtext, PRIMARY KEY (umeta_id), KEY user_id (user_id), KEY meta_key (meta_key(191)) ) DEFAULT CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci

I tried everything and I can’t solve the problem. what can I do? I don´t want to start from scratch with the webpages.

2

Answers


  1. Seems you are trying to CREATE tables in the DB which already exist, if you need the users already present on db, my suggestion is to manually backup the table (by dumping its), remove its (after the dump), and then re-insert them.

    You can easly do that (directly on xampp) by using the PHPMYADMIN panel:

      1. Open XAMPP Control Panel
      1. Start Apache and Mysql Services and go to http://localhost/phpmyadmin/
      1. Here you should be able to find the WordPress Database (in the menù at the left), open it and look for the table citizen by the logs.
      1. export all of them (you should find the export button in the navigation bar upside)
      1. Delete the table after exported.

    Now the CREATE command should works fine. You can re-import the table exported at the point 3 after this procedure

    Login or Signup to reply.
  2. If the database already exists, most likely you have not edited the wp-config.php yet (using any text editor), where you have to insert your database data, like server, db name, db password, db user.

    Here are some more details about this: https://wordpress.org/support/article/how-to-install-wordpress/#step-3-set-up-wp-config-php

    Login or Signup to reply.
Please signup or login to give your own answer.
Back To Top
Search