SupabaseS
Supabase7mo ago
Yifan

How to optimize full text search

CONTEXT:
currently we try to implement a full text search for 5 columns using tsvector and search_vector. Our DB has around 2-3 mill entries and expect to grow greatly in the future.

QUESTION:
Is it best practice to create a new column in our table of the combined tsvectors of the 5 columns we want to search for and do search_vector for that column?

We are currently doing this but still have a bit more latency than we'd like. Is there anyway to optmize?

Thank you!!
Was this page helpful?