Ubuntu connect, create database and restore/import postgresql

22.16 Muhamad Akbar Bin Widayat 0 Comments

PostgreSQL logo.
PostgreSQL logo. (Photo credit: Wikipedia)
Hi everyone,
I want to share to you about setting database postgresql.

1. Connect database
    sudo -u postgres psql postgres
    password: postgres
2. Create database
    sudo -u postgres createdb mydb
3. Restore/import database
    sudo -u postgres psql -d mydb < database.dump

I hope this article can help you guys.
Enhanced by Zemanta

0 komentar:

terimakasih komentarnya