Uploaded image for project: 'MariaDB Server'
  1. MariaDB Server
  2. MDEV-19026

Unable to create a function in mariadb even when function in deterministic

    XMLWordPrintable

Details

    • Bug
    • Status: Closed (View Workflow)
    • Major
    • Resolution: Not a Bug
    • 10.2.15
    • N/A
    • Stored routines
    • None

    Description

      While creating a function in mariadb, I am getting the error - SQL Error (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)

      DELIMITER $$
       
      USE `sbldprod`$$
       
      DROP FUNCTION IF EXISTS `NULLIFZERO`$$
       
      CREATE FUNCTION `NULLIFZERO`(STRING_INPUT VARCHAR(255)) RETURNS VARCHAR(255) 
      	LANGUAGE SQL
      	DETERMINISTIC 
      	CONTAINS SQL
      	sql security invoker
      BEGIN
      	RETURN NULLIF(STRING_INPUT, 0);
      END$$
       
      DELIMITER ;
      

      I am using mariadb on AWS RDS, it's version is 10.2.15.

      *Following are the server params - *
      log_bin_trust_function_creators - 0
      log_bin - 1
      binlog_format - MIXED

      grants on the users creating this function -
      GRANT SELECT, INSERT, UPDATE, DELETE, CREATE, DROP, INDEX, ALTER, LOCK TABLES, EXECUTE, CREATE VIEW, SHOW VIEW, CREATE ROUTINE, ALTER ROUTINE, TRIGGER

      Attachments

        Activity

          People

            Unassigned Unassigned
            anupb anup b
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Git Integration

                Error rendering 'com.xiplink.jira.git.jira_git_plugin:git-issue-webpanel'. Please contact your Jira administrators.