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 'AND WHERE IdEspaco = '5' AND 1=1 AND Status='Habilitado' ORDER BY Data DESC' at line 1