How to create a function in mysql1418 _ MySQL

Source: Internet
Author: User
Mysql1418 solution to function creation failure bitsCN.com


How to create a function in mysql 1418

ErrorCode: 1418

ThisfunctionhasnoneofDETERMINISTIC, NOSQL, orREADSSQLDATAinitsdeclarationandbinaryloggingisenabled (you * might * wanttousethelesssafelog_bin_trust_function_creatorsvariable)

(0 mstaken)

The solution is as follows:

1. mysql> set global log_bin_trust_function_creators = 1;

2. when the system is started -- log-bin-trust-function-creators = 1

3. add a line of log-bin-trust-function-after marking [mysqld] in the my. ini (my. conf in linux) file-
Creators

If there is a 1418 error in the create function: you only need to execute set global log_bin _
Trust_routine_creators = 1;

Then there will be no problem with how to create a function (of course, your function must be correct). This is a bug in mysql,
I don't know why. it's okay to do this anyway.

In addition, you can add the following line [mysqld] log_bin_trust_routine_creators = 1 in the configuration file my. cnf;

This command can be run in the SQL editor environment without restarting the service.

BitsCN.com

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.