Possible Duplicate:
How to write a stored procedure using phpmyadmin and how to use it through php?
I am starting with stored procedures and tried a simple, on every page used query, but get an error i can't solve.
CREATE PROCEDURE ts_open_uitdagingen()
BEGIN
SELECT
COUNT(*) AS open_uitdagingen
FROM
ts_lad_uitdagingen
WHERE
uitgedaagde = '97'
AND acceptdatum IS NULL
AND afwijsdatum IS NULL ;
END;
Errormessage:
1064 - You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '' at line 10
what is wrong with line 10? with or without de semicolon, i get this message?? The query itself is just copied from my script and works well.