Query: SELECT YEAR(obr.erp_obr_data_publicacao) as ano, MONTH(obr.erp_obr_data_publicacao) as mes, obr.erp_obr_codigo, obr.erp_obr_titulo FROM erp_obra obr WHERE obr.erp_obr_publicar_site = 1 AND (erp_obr_validade IS NULL OR erp_obr_validade >= NOW()) AND erp_obr_data_publicacao <= NOW() AND obr.erp_obr_ass_codigo IN() ORDER BY ano ASC, mes ASC, erp_obr_data_publicacao ASC - N: 457 - 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 ') ORDER BY ano ASC, me' at line 17