File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -85,6 +85,7 @@ CREATE DATABASE regress_check_owner OWNER regress_mdb_superuser_user2;
8585SET ROLE regress_mdb_superuser_user2;
8686CREATE SCHEMA regtest;
8787CREATE TABLE regtest.regtest();
88+ GRANT CREATE ON SCHEMA regtest TO regress_mdb_su_role_o2;
8889-- this should fail
8990SET ROLE regress_mdb_superuser_user3;
9091GRANT ALL ON TABLE regtest.regtest TO regress_mdb_superuser_user3;
@@ -96,9 +97,9 @@ GRANT ALL ON TABLE regtest.regtest TO regress_mdb_superuser_user1;
9697ALTER TABLE regtest.regtest OWNER TO regress_mdb_superuser_user1;
9798-- Check grantor
9899SET ROLE regress_mdb_su_role_o2;
99- CREATE TABLE public .role_o2_t();
100+ CREATE TABLE regtest .role_o2_t();
100101SET ROLE mdb_superuser;
101- GRANT SELECT ON public .role_o2_t TO regress_mdb_su_role_o1;
102+ GRANT SELECT ON regtest .role_o2_t TO regress_mdb_su_role_o1;
102103SELECT
103104 grantor
104105from information_schema.role_table_grants
Original file line number Diff line number Diff line change @@ -113,6 +113,8 @@ SET ROLE regress_mdb_superuser_user2;
113113CREATE SCHEMA regtest ;
114114CREATE TABLE regtest .regtest();
115115
116+ GRANT CREATE ON SCHEMA regtest TO regress_mdb_su_role_o2;
117+
116118-- this should fail
117119
118120SET ROLE regress_mdb_superuser_user3;
@@ -127,11 +129,11 @@ ALTER TABLE regtest.regtest OWNER TO regress_mdb_superuser_user1;
127129
128130SET ROLE regress_mdb_su_role_o2;
129131
130- CREATE TABLE public .role_o2_t();
132+ CREATE TABLE regtest .role_o2_t();
131133
132134SET ROLE mdb_superuser;
133135
134- GRANT SELECT ON public .role_o2_t TO regress_mdb_su_role_o1;
136+ GRANT SELECT ON regtest .role_o2_t TO regress_mdb_su_role_o1;
135137
136138SELECT
137139 grantor
You can’t perform that action at this time.
0 commit comments