SELECT
nw.newsid ,
newstitle ,
newsslogan ,
newsdate ,
nw.newstype ,
ct.cityid ,
dst.districtid ,
dst.district_en AS districtname ,
ct.cityname_en AS cityname ,
cat.categoryname_en AS categoryname ,
(SELECT abbr FROM tourexpiutf8_countries WHERE countryid=nw.countryid) AS abbr
FROM tourexpiutf8_news nw
LEFT JOIN tourexpiutf8_cities ct ON ct.cityid = nw.newsregion
LEFT JOIN tourexpiutf8_districts dst ON dst.districtid = ct.district
LEFT JOIN tourexpiutf8_newstypes cat ON cat.typeid = nw.newstype
WHERE
nw.picture='1' AND
nw.isActive='1' AND
nw.newsdate>='1709218631' AND
nw.lang='en' AND
(SELECT abbr FROM tourexpiutf8_countries WHERE countryid=nw.countryid) ='intl'
ORDER BY nw.newsdate DESC LIMIT -8,20
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 '-8,20' at line 23