Skip to main content
InterviewHubPRO
Section Overview
Q47

Question 47 of 50

Part 3: Advanced Internals, Scale & Production Patterns (Senior / Lead)

94%
PostgreSQL Enterprise (50 Qs)•Part 3: Advanced Internals, Scale & Production Patterns (Senior / Lead)

Partial & Expression (Functional) Indexes in PostgreSQL.

senior LevelMost AskedDatabases & SQLPostgreSQL

In Simple Words:

  • Partial Index: Indexes only rows matching a WHERE condition (CREATE INDEX idx_active ON users (email) WHERE is_active = true;). Saves 90% disk space by indexing only the hot slice of data.
  • Expression Index: Indexes the result of a deterministic function (CREATE INDEX idx_lower_email ON users (LOWER(email));), allowing fast case-insensitive lookups without full-table scans.