PostgreSQL
The world's most advanced open-source database
Created
1996 as a derivative of Ingres
Type
Relational database management system
Current version
PostgreSQL 16 (2023)
SQL standard
Most compliant open-source RDBMS
Features
JSON, full-text search, PostGIS, extensions
Used by
Apple, Instagram, Spotify, NASA
License
PostgreSQL License (very permissive)
Best for
Complex queries, geospatial data, extensibility
What is PostgreSQL?
PostgreSQL is the world's most advanced open-source relational database. It's known for standards compliance, extensibility, and handling complex queries that other databases can't.
Why PostgreSQL?
PostgreSQL does everything MySQL does, plus JSON queries, full-text search, geospatial data (PostGIS), custom types, and extensions. It's the default choice for complex, data-heavy applications.
| Feature | PostgreSQL | MySQL | SQLite |
|---|---|---|---|
| SQL compliance | Full | Partial | Partial |
| JSON support | Excellent | Basic | Limited |
| Extensions | PostGIS, pg_trgm, ... | Limited | Loadable modules |
| Concurrency | MVCC (no locks) | MVCC (InnoDB) | Single-writer |
| Best for | Complex apps | Simple web apps | Embedded/mobile |
What you'll learn
| Chapter | What you'll know |
|---|---|
| Introduction | What PostgreSQL is, how to use it |
| Basics | CREATE, SELECT, INSERT, UPDATE, DELETE |
| Joins | Combining tables |
| Advanced | Indexes, JSON, full-text search |
Start with introduction.