We have 2 tables called : "post" and " post\_extra"

summery construction of "post" table's are: `id,postdate,title,description`

And for post\_extra they are: `eid,news_id,rating,views`

"id" filed in the first table is related to "news\_id" to the second table.

There are more than 100,000 records on the table, that many of them are duplicated. I want to keep only one record and remove duplicate records on "post" table that have the same title, and then remove the related record on "post\_extra"

I ran this query on phpmyadmin but the server was crashed. And I had to restart it.

```
DELETE e 
FROM Post p1, Post p2, Post_extra e 
WHERE p1.postdate > p2.postdate 
  AND p1.title = p2.title 
  AND e.news_id = p1.id

```

How can I do this?