MySQL you *might* want to use the less safe log_bin_trust_function_creators variable
在my.ini或者my.cnf文件下添加:log-bin-trust-function-creators=1
然后重启mysql服务就好了, 或者在sql语句里添加:set global log_bin_trust_function_creators=TRUE;(放到returns后面)
CREATE FUNCTION getDeptChild(parentId VARCHAR(40))
RETURNS VARCHAR(4000) set global log_bin_trust_function_creators=TRUE;
BEGIN