MySQL Forums
Forum List  »  Quality Assurance

Procedures Not Working
Posted by: Big K Jr
Date: October 22, 2011 01:10PM

I'm working with procedures for the first time in MySQL, but for some reason I keep getting NULL. My test procedure is a simple one, it just adds.

delimiter $$
create procedure adds(in r double, out a double)
begin
set a = r + r;
end $$
delimiter ;

CALL adds(5, @a);

SELECT @a;

Not sure if I'm doing this right. For @a it just prints out NULL.

Options: ReplyQuote


Subject
Views
Written By
Posted
Procedures Not Working
2047
October 22, 2011 01:10PM
1096
December 01, 2011 04:41AM
1229
December 30, 2011 12:28AM
900
February 13, 2012 03:24AM
882
January 16, 2012 07:30PM


Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.