error en query: SELECT * FROM comision_valor WHERE id_tipo=1 and activo='1' and id_trimestre_anio= and id_producto_comercial=31014 ORDER BY 1 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 id_producto_comercial=31014 ORDER BY 1' at line 1*1064