How to call a mysql stored procedure with arguments from command line

Sample Procedure:
CREATE PROCEDURE Main(Inp tinyint UNSIGNED,OUT Ret tinyint)
BEGIN 
  SET Ret:=Inp+1;
END
Passing Arguments to Procedures:
call Main(@Inp:=5,@Ret);
SELECT @Ret; -- Output Parameter
Example:

Post a Comment

0 Comments