Error!

MySQL Error: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'and user_contents.user_role != '0' and contents.publish_date <= '2024-06-09 16:0' at line 1
SQL Statement: select count(*) as total_records from (SELECT 1 FROM contents JOIN user_contents on contents.id = user_contents.content_id WHERE contents.magazine_id=1 AND contents.content_type_id IN(2772) AND user_contents.user_id= and user_contents.user_role != '0' and contents.publish_date <= '2024-06-09 16:00:00' ORDER BY contents.publish_date DESC ) as t