title: What is dbms_output.put_line equivalent in MySQL or how to display message in MySQL
body: <pre><code>USE `doc1vault`;
  DROP procedure IF EXISTS `EIN_ACCESS1`;
  
  DELIMITER $$
  USE `doc1vault`$$
  CREATE PROCEDURE `EIN_ACCESS1`(/*IN my_EIN VARCHAR(350),*/ IN my_ICODesc VARCHAR(200))
      BEGIN
      DECLARE finished INTEGER DEFAULT 0;
      DECLARE EINLIST varchar(200)  DEFAULT 0;
      DECLARE cur1 CURSOR FOR SELECT * FROM vault_databases where ico_description like CONCAT('%' , my_ICODesc , '%');
      DECLARE CONTINUE HANDLER FOR NOT FOUND SET finished = 1;
          get_rec:LOOP
          FETCH cur1 INTO EINLIST;
              IF finished = 1;
          SELECT 'Record Finished'; /*Gives error hewe*/
          LEAVE get_rec;
          END IF;
          END LOOP get_rec;
          END$$
  DELIMITER ;
  </code></pre>
  
  <p>results in </p>
  
  <blockquote>
    <p>ERROR 1328 (HY000): Incorrect number of FETCH variables</p>
  </blockquote>