1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

How to remove duplicates posted by wp-0-matic

Discussion in 'Blogging' started by bennyb, Mar 26, 2009.

  1. bennyb

    bennyb Regular Member

    Joined:
    Feb 8, 2009
    Messages:
    261
    Likes Received:
    72
    Location:
    Uranus
    Hi there.
    I see alot of folks here complaining about wp-0-matic posting duplicate content. So I wanted to share a solution with BHW comunity.
    To erase duplicate content you need to execute a following SQL query.
    Code:
    DELETE bad_rows.*
    from wp_posts as bad_rows
    inner join (
    select post_title, MIN(id) as min_id
    from wp_posts
    group by post_title
    having count(*) > 1
    ) as good_rows on good_rows.post_title = bad_rows.post_title
    and good_rows.min_id <> bad_rows.id
    For those of you who don't know how to execute SQL query you need to stop autoblogging and start e-whoring... Just Kidding :D

    Just go to your cpanel and open php myadmin.
    Once you re in php myadmin select the database where you want to remove all dupes and run the above mentioned query.
    I usually do that 3 times a week.

    Enjoy :)
     
  2. rawasch

    rawasch Junior Member

    Joined:
    Sep 15, 2008
    Messages:
    142
    Likes Received:
    663
    Thanks but I think someone has already released a free plugin to do this on here, which might be a little easier to use than your query.
     
  3. bennyb

    bennyb Regular Member

    Joined:
    Feb 8, 2009
    Messages:
    261
    Likes Received:
    72
    Location:
    Uranus
    If Iam not mistaking the dupe remover plugin works only when you post a new post.This query removes duplicate posts no matter how long ago it was published.
     
  4. BlackMelvyn

    BlackMelvyn Regular Member

    Joined:
    Jul 8, 2008
    Messages:
    202
    Likes Received:
    272
    Home Page:
  5. bennyb

    bennyb Regular Member

    Joined:
    Feb 8, 2009
    Messages:
    261
    Likes Received:
    72
    Location:
    Uranus
    Does it also removes duplicate posts if title is different?
     
  6. BlackMelvyn

    BlackMelvyn Regular Member

    Joined:
    Jul 8, 2008
    Messages:
    202
    Likes Received:
    272
    Home Page:
    nope, it does not.
    There's a way to do it though