When marking comments as “spam” in WordPress, it doesn’t actually remove them from the database.
From my own experience, most WordPress installations have thousands of spam comments in their databases, taking up valuable space.
In the wp_comments table the comment_approved column will show a value of “spam” on any comment marked as spam – and a value of “1″ for any approved comment.
To quickly delete ALL spam comments, execute the following query on your MySQL database:
You can expand the SQL command to delete from multiple databases and multiple tables, quickly and effectively.