Skip to main content

One post tagged with "full-text-search"

View All Tags

Beyond `LIKE`: Full-Text and Fuzzy Search in ZenStack V3

· 8 min read
Yiming
Co-founder of ZenStack

Cover image

Every ORM gives you contains, startsWith, and endsWith on string fields, and for a while that feels like enough. Then a product manager asks for "search that just works" on a product catalog, and you realize how blunt those operators really are. contains: 'iphone' won't match "iPhones". It won't match "iphne" from a sloppy mobile keyboard. It won't rank a name match higher than a description match. And once your table gets large enough, ILIKE '%term%' quietly stops being free.

ZenStack v3.7 ships two new operators that solve different halves of this problem — full-text search for natural-language content and fuzzy search for short, typo-prone fields — both expressed in the same familiar ORM query API you're already using.