Last active
August 29, 2015 14:01
-
-
Save kishorevaishnav/eea53fe1cca20b38934c to your computer and use it in GitHub Desktop.
Create DB, Add User, Grant Permission. - Postgres
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--To Create the database & add user to that | |
CREATE DATABASE <dbname>; | |
CREATE USER <username>; | |
\password <username> | |
GRANT ALL PRIVILEGES ON DATABASE <dbname> TO <username>; | |
ALTER DATABASE <dbname> OWNER TO <username>; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment