Sunday, 26 April 2015

Installation of Postgres in ubuntu 14.04

sudo apt-get install postgresql postgresql-contrib
sudo -i -u postgres//authenticate as postgres user
sudo -u user_name psql db_name//or u can use this to login directly
psql
createdb test//create db with name as test
\dt //to know tables in db
alter user user_name with password 'new_password';//chage user name delete psql history after query

No comments:

Post a Comment