Bookmark and Share

Quick and dirty postqresql commands

Want to make use of a postqresql database, say for speeding up Amarok? Here's a few quick and dirty commands.

Set the password for the postgres user (replace password with your password):



Add a system user (replace user with your system user name):

sudo -u postgres createuser -D -A -P user

Create a database (replace user with your user name and database with your desired database name):

sudo -u postgres createdb -O user database

Remove a database (replace database with the name of the database you wish to remove):

sudo -u postgres dropdb database