Can any one please help me with this. I didn't use C# a lot , and i need to call MySQL stored procedure with 1 input parameter and i need to write down it query output.
My Stored Procedure:
CREATE DEFINER=`root`@`%` PROCEDURE `SP_For_Insert`(var_username varchar(50))
BEGIN
Declare counter int default 0;
Select Count(username) into counter From users where username = var_username;
if counter = 0 then
select 0 as zero_results;
else
Select username from users where username=var_username;
end if;
END
I know how to call simple query and store result, but i need this to work.