Home > Blogs, Bookmarks, PhP, Wordpress > Error: Unknown column ‘post_id’ in ‘field list’ , Pagination Plugin

Error: Unknown column ‘post_id’ in ‘field list’ , Pagination Plugin

November 25th, 2007 Leave a comment Go to comments

For Pagination Wordpress Plugin

If you request next error in category page :

WordPress database error: [Unknown column ‘post_id’ in ‘field list’]
SELECT count(DISTINCT post_id) FROM wp_posts LEFT JOIN

Try this hack:

1. Open File:

wp-content/plugins/pagination.php

2. Search:

$sqlStr = "SELECT count(DISTINCT post_id) FROM $fromwhere";
(at line 22)

3. Change with:

$sqlStr = "SELECT count(DISTINCT ID) FROM $fromwhere";

4. Save file. DONE !

  1. No comments yet.
  1. No trackbacks yet.
GoCache - ByREV-Cache v1.0 - live served in : 0.197236 sec (gzip)