mysql error explisit or implistr commit not allowed code example
Example: Explicit or implicit commit is not allowed in stored function or trigger.
You are not allowed to perform transactions inside a stored functions. A transaction operation is only allowed inside stored procedure.