I am coming from a SQL background to write some stored procedures for MySQL now that it supports it, I'm having problems with the general syntax of a simple query that takes a variable in and uses it in the where clause of a select query and then returns a recordset.
Here is what I have that seems to be incorrect:
CREATE PROCEDURE test(in variablein int, out recordout int)
DECLARE recordout int;
set recordout = 'SELECT a FROM table WHERE (al = '" : variablein : "')';
Any help would be most appreciated, once i've got one correct I should get the idea for the rest.