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 '-30, 30' at line 1
select HIGH_PRIORITY books.ASIN ASIN FROM amazon.books_whatsnew inner join amazon.books using(ASIN) where books_whatsnew.Stamp >= subdate(now(), interval 10 day) order by books_whatsnew.Stamp desc, SalesRank asc LIMIT -30, 30