Skip to main content

Search Functions

These functions operate on an inverted index — SereneDB's index for full-text, vector and geospatial search. You build a query (most often with the @@ operator and a TSQUERY), optionally rank matches with a relevance scorer and highlight them. The reference is grouped by purpose:

PageFunctions
Full-TextThe @@ match operator, TSQUERY constructors and operators, PostgreSQL-compatible parsers, convenience predicates and ts_lexize
Term DictionaryFacet counts, distinct values, autocomplete and min/max via the ts_dict_* aggregates read from the index dictionary
Vectorl2_distance, cosine_distance, l1_distance and the <-> operator
GeoST_Intersects, ST_Contains, ST_Distance_Between, ST_Distance_Centroid
ScoringBM25, TFIDF and the other relevance scorers
Highlightingts_highlight, ts_offsets

For task-oriented guides see Full-Text Search, Vector Search and Geospatial Search.