I want to consult by several columns with a concatenated value, I put the following example to make me understand
-- Como se llamaría => CALL sp_getSuperConsulta("%val1% %val2% %val3%");
DROP PROCEDURE
IF EXISTS sp_getSuperConsulta;
DELIMITER //
CREATE PROCEDURE sp_getSuperConsulta(IN valorConcat VARCHAR(10000))
BEGIN
SELECT
*
FROM
tabla
WHERE
LOWER(CONCAT_WS(
' '
, col1
, col2
, col3
, col4
)) LIKE LOWER(valorConcat);
END
//
It would be a multi-column query with several parameters