Post count is 0 in admin and sometime error on author page
-
Hello Folks
We have used co-author-plus in our previous site. Later on we have exported and imported all the users IN new site then we have imported all the blog post in the new site. After that we have installed co-author plus. But after that we just realized that in the admin post count for the users is 0 and on frontend some of our users are facing SQL error.
When we disabled this then all the post count are seems fine.
ERROR:
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 ‘4 OR (wp_term_taxonomy.taxonomy = ‘author’ AND wp_term_taxonomy.term_id = ‘11592’ at line 1]
SELECT SQL_CALC_FOUND_ROWS wp_posts.ID FROM wp_posts LEFT JOIN wp_term_relationships AS tr1 ON (wp_posts.ID = tr1.object_id) LEFT JOIN wp_term_taxonomy ON ( tr1.term_taxonomy_id = wp_term_taxonomy.term_taxonomy_id ) WHERE 1=1 AND ((wp_term_taxonomy.taxonomy = ‘author’ AND wp_term_taxonomy.term_id = ‘11176’4 OR (wp_term_taxonomy.taxonomy = ‘author’ AND wp_term_taxonomy.term_id = ‘11592’))) AND wp_posts.post_type = ‘post’ AND (wp_posts.post_status = ‘publish’ OR wp_posts.post_status = ‘archive’ OR wp_posts.post_status = ‘unlist’ OR wp_posts.post_status = ‘private’ OR wp_posts.post_status = ‘archive’ OR wp_posts.post_status = ‘unlist’) GROUP BY wp_posts.ID HAVING MAX( IF ( wp_term_taxonomy.taxonomy = ‘author’, IF ( wp_term_taxonomy.term_id = ‘11592’ OR wp_term_taxonomy.term_id = ‘11176’,2,1 ),0 ) ) <> 1 ORDER BY wp_posts.post_date DESC LIMIT 0, 9 /* From [blogs/author/authorname/] in [index.php:17] */
The topic ‘Post count is 0 in admin and sometime error on author page’ is closed to new replies.