Details
-
Type:
Bug
-
Status: Closed (View Workflow)
-
Priority:
Minor
-
Resolution: Duplicate
-
Affects Version/s: None
-
Fix Version/s: N/A
-
Component/s: Authentication and Privilege System
-
Labels:None
Description
CREATE USER u@'%' IDENTIFIED BY '123'; |
CREATE ROLE r; |
SET DEFAULT ROLE r FOR u@'%'; |
Yields:
ERROR 1959 (OP000): User `root`@`localhost` has not been granted role `r`
|
... when really the problem is a missing grant for user `u` before trying to set the default role:
GRANT r TO u; |
So therefore the error message ought to say something like this instead:
User `u`@`%` has not been granted role `r`
|
I think this behaviour is seen in all versions.
Attachments
Issue Links
- is duplicated by
-
MDEV-26875 Wrong user in SET DEFAULT ROLE error
-
- In Review
-