In the above SQL query we are telling the SQL database server to delete the all comments that comment_approved = spam, it's mean to delete all comments from the database which is spam. BTW wp_ is my prefix if your database prefix is different then change with it. Once to copy the SQL query, then go to phpmyadmin at your cpanel and then to wp_comments table and click on SQL tab and paste that query there and click on go
DELETE FROM `wp_comments` WHERE `comment_approved` = 'spam'
I am Aizaz.Dinho and I loved to learn new things and teach to people like you, In my mind I'm the one who can do anything whatever I want, From my heart am still learner and loved to do impossible things, Web Development is my passion and I have PHP, MYSQL OOP PDO, Blogger WordPress also SEO experiences, You can say I'm the code ninja of meralesson