I am trying to learn how to use MySQL stored procedures. MySQL accepted my procedure:
CREATE PROCEDURE SimpleProc() BEGIN SELECT * FROM myTable; END
(In phpMyAdmin, I set // for the delimiter. The real version has the name of the actual table instead of myTable.).
But when I call the procedure using CALL SimpleProc(); , I get the error "# 1312 - PROCEDURE mydb.SimpleProc cannot return the result set in this context."
I read that some versions of php or phpMyAdmin will not work with stored procedures.
I am using localhost running on Mac with MAMP 1.9. I have MySQL 5.1.44, PHP 5.2.13 and 5.3.2, phpMyAdmin 3.2.5. Does anyone know if stored procedures will work with my setup? Am I doing something wrong? Any tips?
Shout out to Big Red for a triple victory at Lakes.
Thanks Laxmidi
source share