PostgreSQL

From Indie IT Wiki
Revision as of 12:46, 5 September 2013 by imported>Plittlefield
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
sudo su - postgres
psql -d template1 -U postgres
template1=# \c databasename
You are now connected to database "databasename" as user "postgres".
databasename=# \dt
databasename=# \dt
databasename=# SELECT * FROM res_users;

http://crashmag.net/resetting-the-rootpostgres-password-for-postgresql

http://www.postgresql.org/docs/9.1/static/tutorial-select.html