postgresql GRANT ALL ON all tables and views in schema code example Example: postgresql grant all privileges on database GRANT ALL PRIVILEGES ON dbname TO username;