MAC Installation
http://postgresapp.com/
Create and delete database users
The corresponding commands are as follows (in the postgres=# environment):
1. View the list of database users:\du
2. Create a database User:create user user1 with password ‘123456‘;
3. Delete Database users:drop user user1;
The corresponding results are as below:
Creating and Deleting databases
The corresponding commands are as follows (in the postgres=# environment):
1. View the list of databases: \l
(list meaning)
2. Create a database:create database db1;
3. Delete the database:drop database db1;
Creating and Deleting database tables
The corresponding commands are as follows (in the postgres=# environment):
1. Select the database: \c DatabaseName
(choose meaning)
2. Create a database table:create table people;
3. Delete the database table:drop table people;
4. View the database information: \d
(the data list means)
PostgreSQL Configuration Installation