• Anyone able to help me fix this. When I edit a post or post to the ‘jobs’ category I get the following wordpress error, however it does seem to save to the website. The error is just annoying though.

    Any ideas how to fix / what the problem is?…

    WordPress database 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 p2c.category_id <> 2 AND p2c.category_id <> 5 AND p2c.category_id <> 12 A' at line 5]
    SELECT DISTINCT MONTH(p.post_date) AS <code>month</code> FROM wp_posts p INNER JOIN wp_post2cat p2c ON (p.ID = p2c.post_id ) WHERE YEAR(p.post_date) = AND p2c.category_id <> 2 AND p2c.category_id <> 5 AND p2c.category_id <> 12 AND p2c.category_id <> 16 AND p2c.category_id <> 18 AND p2c.category_id <> 20 AND p.post_date_gmt < '2008-06-24 11:20:39' ORDER By p.post_date DESC

    Cheers

The topic ‘Database error when editing or posting to specific category’ is closed to new replies.