時間:2024-02-13 10:22作者:下載吧人氣:34
postgresql 授權(quán)某個數(shù)據(jù)庫的權(quán)限給wang 賬號 使該賬號 只能操作指定DB 不能操作其他DB
alter user wang set default_transaction_read_only=on;
grant all on database test to wang;
grant select on all database test to wang;
grant select on all tables in schema public to wang; // 起作用的是這句 要進入數(shù)據(jù)庫test 操作,在那個db環(huán)境執(zhí)行就授哪個db的權(quán)
網(wǎng)友評論