Tonight I was cleaning up one of my blogs I removed a bunch of spam comments and deleted a few drafts, etc. When I chose to delete the posts permanently from the Trash I was confronted with a horrific issue. All at once, all my posts appeared to be gone. Absolutely vanished before my eyes.

Luckily I’ve worked with computers so long, that I don’t tend to panic. I just start searching for a solution. I went into PHPMyAdmin and checked the wp_posts file. I encountered the following error:

#145 – Table ‘./wp_posts’ is marked as crashed and should be repaired

Ok, so the MySQL database table just needed to be repaired. It hiccuped and needed to be fixed. Now I just needed to know how to repair the table. Although it seemed like there should be a repair table option available in situations like this, this didn’t seem to be a viable option in this case.

Clicking on the WP_POSTS table in PHPMyAdmin only gave me an option to Flush Table. So, I started doing more research. After a few minutes, I found the SQL command I needed to fix it. If you encounter a similar situation, follow the instructions below to bring back the table from the dead.

1) Log into PHPMyAdmin

2) Select the correct MySQL database for your WordPress installation

3) At the top of the screen, click on SQL

4) Erase anything in the box that appears and type the following command in the box


5) Click on GO at the bottom right of the screen and allow it to repair the MySQL table

Now refresh your blog’s home page and your posts should now be there.

Congratulations, you have resurrected your blog posts back from the dead.

Now before you do anything else, BACKUP Your Blog! to avoid any other disasters!


Tagged with:

Filed under: Errors

Like this post? Subscribe to my RSS feed and get loads more!