Answers for "command to give readonly access to a postgres sql user"

SQL
0

command to give readonly access to a postgres sql user

sudo -u postgres psql
CREATE USER username WITH PASSWORD 'your_password';
GRANT CONNECT ON DATABASE database_name TO username;
GRANT USAGE ON SCHEMA schema_name TO username;
GRANT SELECT ON ALL TABLES IN SCHEMA schema_name TO username;
ALTER DEFAULT PRIVILEGES IN SCHEMA schema_name
GRANT SELECT ON TABLES TO username;
Posted by: Guest on September-23-2021

Code answers related to "command to give readonly access to a postgres sql user"

Code answers related to "SQL"

Browse Popular Code Answers by Language