如何将 Postgres 数据库中所有模式的所有表权限授予用户/角色?
以下命令仅授予特定模式而不是整个数据库。
GRANT ALL PRIVILEGES ON ALL TABLES IN SCHEMA schema_name TO username;
Run Code Online (Sandbox Code Playgroud)
例如,
数据库:测试模式:schema1,schema2 测试表内:schema1.table1,schema1.table2,schema2.table1,schema2.table2
如何向数据库内所有模式中找到的所有表提供所有表权限。
postgresql ×1