Error in SQL

Hi,

I got an email with the following:

Database error in Spark Blogger Community

Query:

 
            SELECT `bx_blogs_main`.`ID`, `bx_blogs_main`.`OwnerID`, `bx_blogs_main`.`Description`, COUNT(`bx_blogs_posts`.`PostID`) AS 'PostCount'
            FROM `bx_blogs_main`
            INNER JOIN `bx_blogs_posts` ON `bx_blogs_posts`.`OwnerID` = `bx_blogs_main`.`OwnerID`
            WHERE `PostStatus`='approval'
            GROUP BY `bx_blogs_main`.`ID`
            ORDER BY `PostDate` DESC
            LIMIT -10, 10
        

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 '-10, 10' at line 7

Found error in the file '/home/xxxxxx/public_html/modules/boonex/blogs/classes/BxBlogsDb.php' at line 98.
Called 'db_res' function with erroneous argument #0.

Debug stuff comes below this.....

If you do a search with this:  modules/boonex/blogs/classes/BxBlogsDb.php' at line 98.

You will see many Dolphin sites with this error

Any Ideas?


Regards

Glenn

Quote · 24 Apr 2013

not sure why you have two limits in there..  -10 and 10

anyone mess with the code at all ?

https://dolphin-techs.com - Skype: Dolphin Techs
Quote · 24 Apr 2013
 
 
Below is the legacy version of the Boonex site, maintained for Dolphin.Pro 7.x support.
The new Dolphin solution is powered by UNA Community Management System.