2013-10-18 05:41:13 -07:00
use mysql;
2013-10-18 05:41:25 -07:00
create role test_role1@host1;
ERROR 42000: You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near '@host1' at line 1
create role test_role2@host2, test_role1@host1;
ERROR 42000: You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near '@host2, test_role1@host1' at line 1
2013-10-18 05:41:13 -07:00
create role test_role1;
create role test_role2, test_role3;
2013-10-18 05:41:25 -07:00
select user, host, is_role from user where user like 'test%';
2013-10-18 05:41:13 -07:00
user host is_role
2013-10-18 05:41:25 -07:00
test_role1 Y
test_role2 Y
test_role3 Y
2013-10-18 05:41:13 -07:00
drop role test_role1;
drop role test_role2, test_role3;
create role test_role1;
create role test_role1;
ERROR HY000: Operation CREATE ROLE failed for 'test_role1'
create role test_role1, test_role2;
ERROR HY000: Operation CREATE ROLE failed for 'test_role1'
2013-10-18 05:41:25 -07:00
select user, host, is_role from user where user like 'test%';
2013-10-18 05:41:13 -07:00
user host is_role
2013-10-18 05:41:25 -07:00
test_role1 Y
test_role2 Y
2013-10-18 05:41:13 -07:00
drop role test_role1;
drop role test_role1;
ERROR HY000: Operation DROP ROLE failed for 'test_role1'
drop role test_role1, test_role2;
ERROR HY000: Operation DROP ROLE failed for 'test_role1'
2013-10-18 05:41:25 -07:00
drop role root;
ERROR HY000: Operation DROP ROLE failed for 'root'
create user dummy@'';
drop role dummy;
ERROR HY000: Operation DROP ROLE failed for 'dummy'
drop user dummy@'';
select user, host, is_role from user where user like 'test%';
2013-10-18 05:41:13 -07:00
user host is_role
2014-01-28 21:01:21 +01:00
create role '';
ERROR OP000: Invalid role specification ``.
2014-01-28 21:11:56 +01:00
create role r1;
drop user r1;
ERROR HY000: Operation DROP USER failed for 'r1'
drop role r1;