Município de Almodôvar

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 'IF(aramos>0 and aopenchild>0, (select kmenuid from menus as n where n.adeleted=0' at line 2