WordPress: turn comments off on all post and pages by query

UPDATE wp_posts SET comment_status =  "closed"

Advertisements