22 Indexes on One Table: How Card Search Uses Every Index Type PostgreSQL Has
·9 mins
The magic.cards table carries indexes of every type PostgreSQL offers. A tour of trigram GIN for substring search, GIN for JSONB containment, B-tree for numerics, hash for exact-match fields, and an expression index that unlocks a color identity query that otherwise requires a full table scan.