SQL vs NoSQL
Two families.
Almost every system needs a database, and the first big choice is between two families. Relational databases, which use SQL. And No SQL databases, which come in many shapes.

- Every system stores data
- Relational: SQL
- NoSQL: many shapes
Two families
A relational database stores data in tables, with a fixed set of columns, and links between tables. It supports joins and strong transactions. Postgres and MySQL are examples. No SQL databases relax some of these rules. They often have flexible shapes, and are built to spread across many machines easily.
Relational (SQL)
- Tables, fixed columnsJoins and transactionsPostgres, MySQL
NoSQL
- Flexible shapesSpread across machinesRedis, MongoDB, Cassandra
When to choose which
Here's a simple guide. If your data has clear relationships, like customers, orders, and products, and correctness matters, start with SQL. If you need massive scale for simple lookups, a flexible shape, or very high write rates, consider No SQL. Most companies use both.
| Need | Lean towards |
|---|---|
| Clear relationships, joins | SQL |
| Money, strong correctness | SQL |
| Huge scale, simple lookups | NoSQL |
| Flexible, changing shape | NoSQL |
| Very high write rate | NoSQL |
Summary
Relational databases give tables, joins, and transactions. No SQL databases trade some of that for flexibility and scale. When unsure, start with SQL. Next, the four main kinds of No SQL.
Key takeaways- SQL: structure and safety
- NoSQL: scale and flexibility
- Start with SQL