WordPress.org

Support

Support » Plugins and Hacks » [Resolved] [Plugin: WP Migrate DB] Duplicate records in wp_posts

[Resolved] [Plugin: WP Migrate DB] Duplicate records in wp_posts

Viewing 7 replies - 1 through 7 (of 7 total)
  • Having similar issues here. I have to manually pull out duplicate records before importing them to the other DB. Steps to possibly reproduce:

    1) Migrate DB from site A to site B.
    2) Add posts/content to site B.
    3) Migrate DB from site B to site A.

    So that I could compare my local DB more easily with the dumped data I added ORDER BY ID ASC to the MySQL statement and I no longer have any duplicates. The exact change was:

    $order = ($table == 'wp_posts') ? "ORDER BY ID ASC" : null;
    $table_data = $wpdb->get_results("SELECT * FROM $table $where $order LIMIT {$row_start}, {$row_inc} ", ARRAY_A);

    on line 603 of wp-migrate-db.php.

    Plugin Author Brad Touesnard

    @bradt

    Maybe one of you could send me your database and steps to reproduce so I can get to the bottom of this issue?

    I no longer have the exact database that caused the problem – it has been updated quite a lot. I am unable to recreate the problem on the new database.

    Just had a similar issue with these options checked.

    Do not export spam comments
    Do not export post revisions

    The latest export worked without duplicates unchecking the options above, Maybe it could help.

    Yep same problem.

    Error occurs only when using the tow options as stated above.

    Plugin Author Brad Touesnard

    @bradt

    I’ve implemented MarcGuay’s fix in the latest version (0.4.4) released this week. Thanks Marc!

Viewing 7 replies - 1 through 7 (of 7 total)
  • The topic ‘[Resolved] [Plugin: WP Migrate DB] Duplicate records in wp_posts’ is closed to new replies.