diff options
author | Jeff Davis <jdavis@postgresql.org> | 2023-01-13 14:14:54 -0800 |
---|---|---|
committer | Jeff Davis <jdavis@postgresql.org> | 2023-01-13 14:33:19 -0800 |
commit | c44f6334ca6ff6d242d9eb6742441bc4e1294067 (patch) | |
tree | 96737157311289cfc4ffbebe74ada84016423a76 /src/backend/utils/adt/pgstatfuncs.c | |
parent | b7ae03953690a1dee455ba3823cc8f71a72cbe1d (diff) | |
download | postgresql-c44f6334ca6ff6d242d9eb6742441bc4e1294067.tar.gz postgresql-c44f6334ca6ff6d242d9eb6742441bc4e1294067.zip |
Simplify permissions for LOCK TABLE.
The prior behavior was confusing and hard to document. For instance,
if you had UPDATE privileges, you could lock a table in any lock mode
except ACCESS SHARE mode.
Now, if granted a privilege to lock at a given mode, one also has
privileges to lock at a less-conflicting mode. MAINTAIN, UPDATE,
DELETE, and TRUNCATE privileges allow any lock mode. INSERT privileges
allow ROW EXCLUSIVE (or below). SELECT privileges allow ACCESS SHARE.
Reviewed-by: Nathan Bossart
Discussion: https://postgr.es/m/9550c76535404a83156252b25a11babb4792ea1e.camel%40j-davis.com
Diffstat (limited to 'src/backend/utils/adt/pgstatfuncs.c')
0 files changed, 0 insertions, 0 deletions