232312 发表于 2014-7-15 14:18:52

postgres数据库查看用户权限

1、查看某用户的表权限
1
select * from information_schema.table_privileges where grantee='user_name';




2、查看usage权限表
1
select * from information_schema.usage_privileges where grantee='user_name';




3、查看存储过程函数相关权限表
1
select * from information_schema.routine_privileges where grantee='user_name';




4、建用户授权

1
2
3
create user user_name;
alter user user_namewith password '';
alter user user_namewith CONNECTION LIMIT20;#连接数限制



页: [1]
查看完整版本: postgres数据库查看用户权限