An open API service indexing awesome lists of open source software.

https://github.com/blackiq/know-postgres

A practical, example-driven guide to PostgreSQL, from SQL fundamentals to PostgreSQL-specific features.
https://github.com/blackiq/know-postgres

cheatsheet database examples knowx learning postgresql reference sql tutorial

Last synced: 1 day ago
JSON representation

A practical, example-driven guide to PostgreSQL, from SQL fundamentals to PostgreSQL-specific features.

Awesome Lists containing this project

README

          

# PostgreSQL Cheat Sheet

A very simple, good, fast way to learn **PostgreSQL** (if you already know SQL) also you may learn SQL here too.

## Chapters

It has kind of everything a beginer need to know. Even `JOIN` or other things. But in category:

- `TABLE`: Create, Drop, Truncate, Not NULL stuff
- `SELECT`: All columns, specified columns
- `INSERT`: Simple way, specified columns, insert many
- `WHERE`: Covering important things like between, less, more and etc
- `UPDATE`: Updating single row and multi rows with WHERE
- `DELETE`: Deleting single row and multi rows with WHERE
- `ORDER BY`: Sorting one col, more than one col having ASC and DESC
- `GROUP BY`: Base of grouping and aggrigation
- `HAVING`: Maybe another time I'll add it
- `LIMIT`: Using sort and limit
- `ALTER TABLE`: Add columns, remove columns
- `Multi Table`: Having more than 1 tables
- `FOREIGN KEY`: Relation Matters Most (RMM)
- `JOIN`: A brief of how is join working. **EVEN GOD DOESN'T KNOW**
- `JOIN`: Using INNER, LEFT, RIGHT and FULL. **EVEN GOD DOESN'T KNOW**
- `Relations`: One to One (1:1), One to Many (1:N), Many to Many (N:N)

## Why PostgreSQL cheat sheet?

This is 1:30 AM Jun 13 here in Tehran, ran out of Melatonin pils. So, creating this cheat sheet is only thing I could do.

---

### Enjoy :)