by sequence7 on 4/25/23, 7:25 AM with 19 comments
by simonw on 4/27/23, 12:14 AM
It does have one surprising limitation: it calculates relevance based on just the current row, rather than being able to take statistics across the whole corpus into account.
Most search engines use TF/IDF or BM25 for relevance calculations, which consider the relative common-ness of terms in comparison to the rest of the corpus. PostgreSQL FTS can't do that as far as I know.
SQLite's built-in FTS CAN do relevance calculations like this! Surprising to see a feature as significant as that show up in SQLite but not in PostgreSQL.
by sequence7 on 4/25/23, 7:25 AM
by pmarreck on 4/27/23, 12:09 AM
It’s fantastic having 1 less dependency though!
One caveat- if you migrate any field in the indexed table, you will likely have to drop and recreate all your triggers and stored procs again
by po on 4/27/23, 1:20 AM
by koromak on 4/27/23, 2:08 PM
I've never implemented full text search using a dedicated database so maybe 1M is too much to ask for.
by nonethewiser on 4/27/23, 12:41 AM
by leonardo2204 on 4/27/23, 1:08 AM
by nbashaw on 4/27/23, 1:09 AM