• mnasimul

    (@mnasimul)


    When I import database.sql, I get the following error. I checked the entire internet with NO straightforward solution. Please do not answer assuming me an expert. Please answer in detail. Thank you

    Error
    SQL query:

    CREATE TABLE wp_commentmeta (
    meta_id bigint(20) UNSIGNED NOT NULL,
    comment_id bigint(20) UNSIGNED NOT NULL DEFAULT ‘0’,
    meta_key varchar(255) COLLATE utf8mb4_unicode_ci DEFAULT NULL,
    meta_value longtext COLLATE utf8mb4_unicode_ci
    ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci
    MySQL said: Documentation

    #1050 – Table ‘wp_commentmeta’ already exists

Viewing 3 replies - 1 through 3 (of 3 total)
  • mairajan

    (@mairajan)

    Error message suggests that your database already have contents in it, thus overwriting the existing table. Are you using a newly created database?

    mairajan

    (@mairajan)

    Thread Starter mnasimul

    (@mnasimul)

    This is new database. I exported to desktop and replaced localhost to my domain. When attempted to import, it gives error.

    I checked without changing anything. Just exported and attempted to import with no change. It still gives the same message. I tried with command CREATE TABLE IF NOT EXISTS. That did not help either. or DROP TABLE IF EXISTS.

    I am quite surprise, experts have NO straightforward answer. I spent golden 6 hours in ytube and google.

Viewing 3 replies - 1 through 3 (of 3 total)

The topic ‘SQL Syntax error’ is closed to new replies.