Fatal error: Uncaught mysqli_sql_exception: 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 'prestacao.idsecretaria = 3 ORDER BY prestacao.ano DESC' at line 6 in /home/transparencia.delmirogouveia.al.gov.br/public_html/lrf/exportar/gxls.php:31 Stack trace: #0 /home/transparencia.delmirogouveia.al.gov.br/public_html/lrf/exportar/gxls.php(31): mysqli_query() #1 {main} thrown in /home/transparencia.delmirogouveia.al.gov.br/public_html/lrf/exportar/gxls.php on line 31