
DROP PROCEDURE IF EXISTS sp_alm_producto_list;
DELIMITER $$
CREATE  PROCEDURE `sp_alm_producto_list`(IN `produc` VARCHAR(100))
    NO SQL
BEGIN

SELECT CONCAT(name, "(",code,")") as productos, id 
FROM tec_products 
WHERE ((name like concat('%',produc,'%')) or (code like concat('%',produc,'%'))) and estado = 1
limit 100;

END$$
DELIMITER ;