Error Catched!

Message:
You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near ') AND (a.type = 206) ORDER BY dtime DESC LIMIT 2000' at line 1

Query:
SELECT title, lastdatetime as dtime, username AS source, CAST( a.id AS CHAR CHARACTER SET utf8 ) AS linkkey FROM zf_contentpages a, zf_user b WHERE a.lastid = b.id AND ( ) AND (a.type = 206) ORDER BY dtime DESC LIMIT 2000