Skip to content

Instantly share code, notes, and snippets.

@ryanhs
Last active May 10, 2023 04:18
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save ryanhs/646b98a39f30d81e0b00b62d78263d78 to your computer and use it in GitHub Desktop.
Save ryanhs/646b98a39f30d81e0b00b62d78263d78 to your computer and use it in GitHub Desktop.
postgre grants example
CREATE USER someuser WITH PASSWORD 'somepass';
GRANT ALL PRIVILEGES ON DATABASE somedb to someuser;
-- on database
GRANT ALL PRIVILEGES ON ALL TABLES IN SCHEMA public TO someuser;
GRANT ALL PRIVILEGES ON ALL SEQUENCES IN SCHEMA public TO someuser;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment