What is wrong with this SQL statement? I cannot get this statement running on MySQL server:

DECLARE @tabl varchar(40)
SET @tabl = :uId;
SET @location = CONCAT('data_',@tabl);
SET @b = 'INSERT INTO' + @location + '(Id, uId , name , address, phone)
VALUES (:Id, :uId, :name, :address)';
Prepare stmt FROM @b;
Execute stmt;


I get this error:


  No value specified for parameter 1 - SQLException  


Bindings will be done in another function.

How can I fix it?
I am not sure what you mean by


  Bindings will be done in another function.


You have an EXECUTE statement that is going to invoke your query right there and then, and that statement is not providing parameter values for your :name parameters. That is what the error message is about.

Your EXECUTE statement must have a USING clause, as per the manual:

EXECUTE stmt
USING @Id, @uId, @name, @address;


where @Id, @uId, @name, @address would probably be the names of arguments of the stored program containing the script in your question.

And then you will also need to address the issues mentioned by Julien Vavasseur and ypercubeᵀᴹ:


revisit the number of values vs the number of columns in the INSERT statement (and correct the USING clause above if necessary);
make sure your INSERT statement is syntactically correct (no missing spaces between its various tokens where required).