PostgreSQL vs Other RDBMS
Pedal's new investor asks why the team chose PostgreSQL rather than MySQL or SQL Server. "Everyone uses it" is not an answer a DBA should give. The honest answer lists what PostgreSQL does well, and what it makes you manage yourself.
The rule
PostgreSQL: free, strict, extensible, one process per connection.
Each word is a real difference from the other popular relational systems:
- Free: released under the PostgreSQL Licence, a short permissive licence. No paid editions and no per-core fees, unlike Oracle or SQL Server.
- Strict: it follows the SQL standard closely and rejects bad input instead of guessing. Inserting
'abc'into an integer column is an error, not a silent zero. - Extensible: you can add data types, functions, index types and whole features as extensions, such as PostGIS for maps or pgvector for embeddings.
- One process per connection: every client connection gets its own operating-system process on the server. This is simple and robust, but each process costs memory, so thousands of idle connections hurt. Busy systems put a connection pooler such as PgBouncer in front.
PostgreSQL also runs DDL inside transactions. A migration that fails halfway can be rolled back completely:
BEGIN;
ALTER TABLE bikes ADD COLUMN battery_pct smallint;
ALTER TABLE rentals ADD COLUMN distance_km numeric(6,2);
ROLLBACK; -- both changes vanish, the tables are untouchedIn MySQL, most DDL statements commit on their own, so the first change would stay.
A quick map of the neighbours:
| System | Typical reason to pick it |
|---|---|
| MySQL / MariaDB | Very common in web hosting, simple replication |
| SQL Server | Deep ties to the Microsoft ecosystem |
| Oracle | Large enterprises with existing contracts and tooling |
| SQLite | Embedded in an app, no server at all |
The shortcut
Turn the rule into four checks against any requirement: cost, correctness, features, connections.
Cost
Pedal is small and wants no licence bill. PostgreSQL is free for any use.
The trap is treating SQLite as a small PostgreSQL. SQLite is a library inside one program with one writer at a time. It is superb on a phone, but it is not a shared server for many clients.
Drills
Answer fast — trust the rule.
How does PostgreSQL handle each new client connection?
A migration runs two ALTER TABLE statements inside BEGIN and the second fails. What happens in PostgreSQL?
Which need points to SQLite rather than PostgreSQL?
What is the usual fix when an app opens thousands of mostly idle connections to PostgreSQL?
Remember
- PostgreSQL: free, strict, extensible, one process per connection.
- Check any choice against cost, correctness, features and connections.
- SQLite is an embedded library, not a small server; DDL in PostgreSQL can be rolled back.
