This function has none of DETERMINISTIC, NO SQL, or READS SQL DATA

来源:互联网 发布:mac程序卸载 编辑:程序博客网 时间:2024/06/05 15:57

This function has none of DETERMINISTIC, NO SQL, or READS SQL DATA in its declaration and binary

mysql的设置默认是不允许创建函数


解决办法1:

执行:

SET GLOBAL log_bin_trust_function_creators = 1;

不过 重启了 就失效了

注意: 有主从复制的时候 从机必须要设置  不然会导致主从同步失败



解决办法2:

在my.cnf里面设置

log-bin-trust-function-creators=1

不过这个需要重启服务


原创粉丝点击