PostgreSQL Configuration Installation

Source: Internet
Author: User
Tags postgresql

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

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.