【问题标题】:Cannot Create Trigger on MYSQL AWS RDS无法在 MYSQL AWS RDS 上创建触发器
【发布时间】:2016-01-25 17:50:21
【问题描述】:

我正在尝试在我的数据库上创建一个触发器,该数据库位于 MYSQL AWS RDS 实例中。 当我尝试下面的代码时:

DELIMITER $$
USE database_name $$
CREATE DEFINER=oldloginuser@localhost trigger newtrigger after update on db_col
for each row
begin
  if new.hits != old.hits then
    insert into log(id, access_time) values (new.id, now());
  end if;
end

我收到以下错误:

Error Code: 1419. You do not have the SUPER privilege and binary logging is enabled (you *might* want to use the less safe log_bin_trust_function_creators variable)

我该如何解决这个问题?

【问题讨论】:

标签: mysql amazon-web-services mysql-workbench


【解决方案1】:

您必须更改数据库参数组值。

您可以在 RDS -> 选择数据库 -> 配置 -> 数据库参数组 -> 单击默认参数组,您将被重定向到数据库参数组页面 -> 使用选项创建新的数据库参数组

并重启数据库;

【讨论】:

    猜你喜欢
    • 2020-11-22
    • 2012-06-27
    • 2013-12-12
    • 1970-01-01
    • 2019-04-16
    • 1970-01-01
    • 2018-07-15
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多