Guides ยท Technology

Database Indexing Basics

Speed up queries

Indexing adds data structures that speed WHERE, JOIN, and ORDER BY queries at the cost of write overhead and space; choose keys carefully.

Pick Columns

Index columns with high selectivity used in filters and joins.

Design Keys

Use composite indexes in filter order; avoid redundant indexes.

Maintain

Monitor bloat and writes; drop unused indexes.

Related Terms