Details
-
Bug
-
Status: Confirmed (View Workflow)
-
Minor
-
Resolution: Unresolved
-
10.6.12, 10.4(EOL), 10.5, 10.6, 10.7(EOL), 10.8(EOL), 10.9(EOL), 10.10(EOL), 10.11
-
None
-
None
Description
If you have a routine where the definer is set to a role, and that role doesn't have execute permission; the error message is execute command denied to user ''@'' instead of execute command denied to user 'role_name'.
Example Script:
CREATE ROLE 'test_role'; |
CREATE USER 'test_user'@'%' IDENTIFIED BY 'SDDSAghghgjhgsa123!!'; |
CREATE DATABASE `test_database`; |
CREATE DEFINER='test_user' PROCEDURE `test_database`.`test_proc`() BEGIN END; |
CREATE DEFINER='test_role' PROCEDURE `test_database`.`test_proc2`() BEGIN END; |
CALL `test_database`.`test_proc`;
|
/* Output: execute command denied to user 'test_user'@'%' for routine 'test_database.test_proc' */
|
CALL `test_database`.`test_proc2`;
|
/* Output: execute command denied to user ''@'' for routine 'test_database.test_proc2' */
|
DROP DATABASE `test_database`; |
DROP USER 'test_user'; |
DROP ROLE 'test_role'; |