Last active
September 13, 2020 17:28
-
-
Save tsolar/9d93d2e20304c9c7e52b59ca7ffa200a to your computer and use it in GitHub Desktop.
postgresql create database
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
su - postgres | |
psql | |
CREATE ROLE rolename WITH LOGIN PASSWORD 'password'; | |
CREATE DATABASE databasename OWNER rolename; | |
# working 2020-09-13 | |
sudo -u postgres -i | |
psql | |
CREATE ROLE tom WITH LOGIN PASSWORD 'password'; | |
ALTER ROLE tom WITH SUPERUSER; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment