0% found this document useful (0 votes)
126 views

Postgre SQL

PostgreSQL is an open source object-relational database system that uses and extends SQL. It can safely store and scale complex data workloads. Some key features include a wide variety of data types for structured and unstructured data, data integrity constraints, and support for SQL and NoSQL features. The document provides instructions on installing PostgreSQL and getting started with some basic SQL commands to create tables, insert data, and run queries. It also cautions that tables will be created in the public schema by default if no schema is specified, and how to specify a schema to query tables from other schemas.

Uploaded by

đức đỗ
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
126 views

Postgre SQL

PostgreSQL is an open source object-relational database system that uses and extends SQL. It can safely store and scale complex data workloads. Some key features include a wide variety of data types for structured and unstructured data, data integrity constraints, and support for SQL and NoSQL features. The document provides instructions on installing PostgreSQL and getting started with some basic SQL commands to create tables, insert data, and run queries. It also cautions that tables will be created in the public schema by default if no schema is specified, and how to specify a schema to query tables from other schemas.

Uploaded by

đức đỗ
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
You are on page 1/ 18

PostgresSQL

A new thing to learn


Table of contents

01 02
PostgreSQL Install
What is PostgreSQL ? How to install PostgreSQL

03 04
Get started Caution
Practice with some line Cautions
of code
Whoa!
Getting start right away
01
PostgreSQL
What is PostgreSQL ?
About Post

PostgreSQL is a powerful, open source object-relational


database system
They’re
● uses and extends the SQL language combined with
many features
●  safely store and scale the most complicated data
workloads
And the most important thing: PostgreSQL is easy to use
 Various features in PostgreSQL
Data Types
Primitives: Integer, Numeric, String, Boolean
Structured: Date/Time, Array, Range / Multirange, UUID
Document: JSON/JSONB, XML, Key-value (Hstore)
Geometry: Point, Line, Circle, Polygon
Customizations: Composite, Custom Types

UNIQUE, NOT NULL Data Integrity


Primary Keys
Foreign Keys
Exclusion Constraints
Explicit Locks, Advisory Locks
“PostgreSQL support SQL and
NoSQL and alot of advance
features.”

Some special
What new ?

Mercury
It’s the closest planet to the Sun and the smallest one

Venus
Venus is the second planet from the Sun

Mars
Despite being red, Mars is actually a cold place
02
Childhood
You can describe the topic
of the section here
“Just follow some video on
youtube step by step.”

—Youtube
03
Get started
Practice with some line of
code
create table users(
id int primary key,
name varchar(20),
age int,
address varchar(126)
);
Syntax is similar to
Oracal or MySQL insert into users(id, name, age, address) values (1,
'duc', 21, 'hanoi');

select * from users;


04
Caution
Some spectial of PostgreSQL
Create a table

If user don’t have a new schema and


create a table, that table will save in
public schema
Create Schema

A schema likes a database in


MySQL. It can save list of table
and support user to select data
from that table

To create new schema, use: create schema <schema_name>;


Get data from new schema

If user not config schema in query, schema public will be


used. To get data from another schema, use:

“select * from <schema_name>.<table_name>;”


About new database

failwall world random


Database still is a User can switch bettwen Only one database can
database multiple database by use be use at time
“\c <database_name>”

You might also like

pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy