Difference between revisions of "ERROR: permission denied for relation"
Jump to navigation
Jump to search
Line 8: | Line 8: | ||
SELECT grantor, grantee, table_schema, table_name, privilege_type FROM information_schema.table_privileges WHERE grantee = 'myuser' | SELECT grantor, grantee, table_schema, table_name, privilege_type FROM information_schema.table_privileges WHERE grantee = 'myuser' | ||
+ | |||
+ | == Related == | ||
+ | * [[GRANT SELECT ON mytable TO xxx]] | ||
== See also == | == See also == |
Revision as of 11:54, 27 September 2022
GRANT ALL PRIVILEGES ON TABLE your-table TO your-user;
SELECT grantee, privilege_type FROM information_schema.role_table_grants WHERE table_name='mytable';
SELECT grantor, grantee, table_schema, table_name, privilege_type FROM information_schema.table_privileges WHERE grantee = 'myuser'
Related
See also
- PostgreSQL: Database roles,
CREATE USER
,CREATE ROLE
,\du, \du+
,create user, Alter user
GRANT
,\ddp
,GRANT USAGE
,GRANT ALL PRIVILEGES
,GRANT SELECT
, View GRANTs on Redshift,has_table_privilege
,has_schema_privilege
,HAS_DATABASE_PRIVILEGE
,SCHEMA
, Privileges,GRANT EXECUTE
- PostgreSQL:
psql
,.psqlrc, .pgpass
,$HOME/.pg service.conf
,-U, -W, -d
, meta-commands:\du, \dg, \ddp, \dp, \list, \dn, \dt, \c, \l, \di, \q
,show users
,show
,su - postgres
,psql -c, \?, \connect, \conninfo
,--version, --help
, PL/pgSQL
Advertising: