Home

Thursday, 4 April 2013

How To Delete All Comments in WordPress.


WordPress sites contained thousands of spam comments.There is no simple way of cleaning up huge amounts of comments.It would take time to delete all of those comments with the WordPress GUI front-end.

so, we will use SQL Command to delete all comment quickly.

Note:-Before doing this please remember to make a backup of your DataBase.

How to Do :-

1.Log in your Cpanel of your wordpress site.

2.Go to phpmyadmin, select your WordPress database.

3.Click the SQL tab, and enter the following query:

To Delete All Comments Awaiting(unapproved) Moderation in WordPress:

delete from wp_comments WHERE comment_approved ="0";


SQL Command to Delete all Approved Comments in WordPress:

delete from wp_comments WHERE comment_approved ="1";

SQL Command to Delete ALL Comments In WordPress:


delete from wp_comments;