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 cp.id_producto<2261 and p.publicar_producto=1 and p.id_producto n' at line 4