I can use MySQL stored procedures with one parameter but when I try and use multiple parameters the stored procedure doesn't seam to be called. I will paste the php code I have then the SQL code. Can anyone give any indication why it's not working?
Thanks
<?php
//DB Connection include
include '/connection/proccon.php';
$skill=1;
$level=1;
$user=1;
//SQL for identify user
$sqlquestion = sprintf("call updatequestion('%s, %s, %s')", $skill, $user, $level);
echo $sqlquestion;
$resultquestion = mysqli_query($link, $sqlquestion);
?>
SQL Below
--Procedure: updatequestion
--DROP PROCEDURE IF EXISTS updatequestion;
DELIMITER |
CREATE DEFINER = 'root'@'%' PROCEDURE updatequestion
(
IN v_uid int,
IN v_level int,
IN v_qid int
)
BEGIN
INSERT INTO answer (qid,uid,level) VALUES(v_qid,v_uid,v_level);
END|
DELIMITER ;