mirror of
https://github.com/MariaDB/server.git
synced 2025-08-01 03:47:19 +03:00
5.0-bugteam->5.1-bugteam merge
This commit is contained in:
@ -459,7 +459,7 @@ Privilege Context Comment
|
||||
Alter Tables To alter the table
|
||||
Alter routine Functions,Procedures To alter or drop stored functions/procedures
|
||||
Create Databases,Tables,Indexes To create new databases and tables
|
||||
Create routine Functions,Procedures To use CREATE FUNCTION/PROCEDURE
|
||||
Create routine Databases To use CREATE FUNCTION/PROCEDURE
|
||||
Create temporary tables Databases To use CREATE TEMPORARY TABLE
|
||||
Create view Tables To create new views
|
||||
Create user Server Admin To create new users
|
||||
|
@ -200,7 +200,7 @@ Field Type Null Key Default Extra
|
||||
f1 char(4) YES NULL
|
||||
show create view v2;
|
||||
View Create View character_set_client collation_connection
|
||||
v2 CREATE ALGORITHM=UNDEFINED DEFINER=`testdb_2`@`localhost` SQL SECURITY DEFINER VIEW `test`.`v2` AS select `v1`.`f1` AS `f1` from `testdb_1`.`v1` latin1 latin1_swedish_ci
|
||||
v2 CREATE ALGORITHM=UNDEFINED DEFINER=`testdb_2`@`localhost` SQL SECURITY DEFINER VIEW `v2` AS select `v1`.`f1` AS `f1` from `testdb_1`.`v1` latin1 latin1_swedish_ci
|
||||
show create view testdb_1.v1;
|
||||
ERROR 42000: SHOW VIEW command denied to user 'testdb_2'@'localhost' for table 'v1'
|
||||
select table_name from information_schema.columns a
|
||||
|
@ -3505,7 +3505,7 @@ USE `mysqldump_views`;
|
||||
/*!50001 SET collation_connection = latin1_swedish_ci */;
|
||||
/*!50001 CREATE ALGORITHM=UNDEFINED */
|
||||
/*!50013 DEFINER=`root`@`localhost` SQL SECURITY DEFINER */
|
||||
/*!50001 VIEW `mysqldump_views`.`nasishnasifu` AS select `mysqldump_tables`.`basetable`.`id` AS `id` from `mysqldump_tables`.`basetable` */;
|
||||
/*!50001 VIEW `nasishnasifu` AS select `mysqldump_tables`.`basetable`.`id` AS `id` from `mysqldump_tables`.`basetable` */;
|
||||
/*!50001 SET character_set_client = @saved_cs_client */;
|
||||
/*!50001 SET character_set_results = @saved_cs_results */;
|
||||
/*!50001 SET collation_connection = @saved_col_connection */;
|
||||
|
@ -28,7 +28,7 @@ create view v2 as select * from mysqltest.t2;
|
||||
ERROR 42000: ANY command denied to user 'mysqltest_1'@'localhost' for table 't2'
|
||||
show create view v1;
|
||||
View Create View character_set_client collation_connection
|
||||
v1 CREATE ALGORITHM=UNDEFINED DEFINER=`mysqltest_1`@`localhost` SQL SECURITY DEFINER VIEW `test`.`v1` AS select `mysqltest`.`t1`.`a` AS `a`,`mysqltest`.`t1`.`b` AS `b` from `mysqltest`.`t1` latin1 latin1_swedish_ci
|
||||
v1 CREATE ALGORITHM=UNDEFINED DEFINER=`mysqltest_1`@`localhost` SQL SECURITY DEFINER VIEW `v1` AS select `mysqltest`.`t1`.`a` AS `a`,`mysqltest`.`t1`.`b` AS `b` from `mysqltest`.`t1` latin1 latin1_swedish_ci
|
||||
grant create view,drop,select on test.* to mysqltest_1@localhost;
|
||||
use test;
|
||||
alter view v1 as select * from mysqltest.t1;
|
||||
@ -309,7 +309,7 @@ grant create view,select on test.* to mysqltest_1@localhost;
|
||||
create view v1 as select * from mysqltest.t1;
|
||||
show create view v1;
|
||||
View Create View character_set_client collation_connection
|
||||
v1 CREATE ALGORITHM=UNDEFINED DEFINER=`mysqltest_1`@`localhost` SQL SECURITY DEFINER VIEW `test`.`v1` AS select `mysqltest`.`t1`.`a` AS `a`,`mysqltest`.`t1`.`b` AS `b` from `mysqltest`.`t1` latin1 latin1_swedish_ci
|
||||
v1 CREATE ALGORITHM=UNDEFINED DEFINER=`mysqltest_1`@`localhost` SQL SECURITY DEFINER VIEW `v1` AS select `mysqltest`.`t1`.`a` AS `a`,`mysqltest`.`t1`.`b` AS `b` from `mysqltest`.`t1` latin1 latin1_swedish_ci
|
||||
revoke select on mysqltest.t1 from mysqltest_1@localhost;
|
||||
select * from v1;
|
||||
ERROR HY000: View 'test.v1' references invalid table(s) or column(s) or function(s) or definer/invoker of view lack rights to use them
|
||||
|
Reference in New Issue
Block a user