Oct
30
2009
Shell Script To Configure A Read Only User On A PostgreSQL Database
Posted by alex in Code Snippets**UPDATE: New article here.
Its a little more complicated to create a read only database user with PostgreSQL than say using something like MySQL. You will need to grant select access on each table in the database for the read only user. Keep in mind that each time you add a new table you will need to either run the shell script below again or manually grant select access on the new table for the read only user.
Tags: .sh, chmod, chown, database, grant, information_schema, pgsql, postgres, PostgreSQL, psql, read only, select, shell script, sql, table, user








Entries (RSS)