WHERE open <> '10' AND thread.visible = 1 AND thread.forumid NOT IN(3,8,25,9,16,27,11,28,26,10,22,15,23,29,4,12,13,5,14,17,15,17,23) Array AND deletionlog.primaryid IS NULL