Akismet navigation generated mySQL error
|Reported by:||vlogtheimpaler||Owned by:||anonymous|
I just stumbled across this while paging through comments captured via Akismet. Not sure if it's perfectly reproducible but you'll need at least 2 pages of captured spam (51+ spam comments). I could not find a duplicate of this in trac so here's the breakdown:
Step 1. Navigate to page 2 of comments marked as spam.
Step 2. Using the supplied links on the page, navigate back to page 1
Step 3. Witness a WordPress Database Error message which appears something like the following:
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 '-50, 0' at line 1]
SELECT * FROM PREFIX_comments WHERE comment_approved = 'spam' ORDER BY comment_date DESC LIMIT -50, 0
No results found.
However it still manages to report that "There are currently 76 comments identified as spam." but does not display the list of the previous spam comments.
the MySQL version on this server is 5.0.18 running under PHP 5.