zoukankan      html  css  js  c++  java
  • MySQL 创建函数失败提示1418

    MySQL 创建函数失败提示1418

    在创建函数时,往往会遇到创建函数失败的情形,除去书写的创建函数的sql语句本身语法错误之外,还会碰到一个错误就是,

    1418:This function has none of DETERMINISTIC, NO SQL,or READS SQL DATA in its declaration and binary logging is enabled(you might want to use the less safe log_bin_trust_function_creators variable)

    当提示这种错误的时候,解决方法如下:

    一、查看创建函数的功能是否开启:

    mysql> show variables like '%func%';
    +-----------------------------------------+-------+
    | Variable_name | Value |
    +-----------------------------------------+-------+
    | log_bin_trust_function_creators | ON    |
    +-----------------------------------------+-------+
    1 row in set (0.02 sec)

    二、如果Value处值为OFF,则需将其开启。
    mysql> set global log_bin_trust_function_creators=1;
     
    三、创建函数
    语法略过,可以通过Navicat工具操作,简单快捷
  • 相关阅读:
    P1127
    CF274D
    BZOJ1477: 青蛙的约会
    BZOJ2770: YY的Treap
    2017-10-湖南套题2
    BZOJ——2697: 特技飞行
    洛谷——P1621 集合
    2017-10-湖南套题1
    项目包结构初始化
    Maven的pom文件配置
  • 原文地址:https://www.cnblogs.com/cyfblogs/p/9883733.html
Copyright © 2011-2022 走看看