🗄️ Database Design / Normalization
Intermediate
What is database partitioning?
Answer
Partitioning divides a large table into smaller physical segments while keeping it logically as one table. Types: Range partitioning — by value ranges (e.g., orders by year: 2022_orders, 2023_orders); List partitioning — by specific values (e.g., by country); Hash partitioning — hash of a key distributes rows evenly; Composite partitioning — combination. Benefits: query performance (partition pruning scans only relevant partitions), faster maintenance (drop a partition instead of deleting millions of rows), and better data lifecycle management. Supported natively in PostgreSQL, MySQL 8+, Oracle, SQL Server.
More Database Design / Normalization Questions
View all →- Intermediate What are database anomalies and how does normalization prevent them?
- Intermediate What is denormalization and when is it used?
- Intermediate What are isolation levels in database transactions?
- Intermediate What are dirty reads, non-repeatable reads, and phantom reads?
- Intermediate What is query optimization and what is a query execution plan?