Full-Text Retrieval

Full text searching (or just text search) provides the capability to identify natural-language documents that satisfy a query, and optionally to sort them by relevance to the query. The most common type of search is to find all documents containing given query terms and return them in order of their similarity to the query.

Textual search operators have been used in databases for years. The GaussDB(DWS) has ~, ~*, LIKE, and ILIKE operators for textual data types, but they lack many essential properties required by modern information systems. This problem can be solved by using indexes and dictionaries.

The hybrid data warehouse (standalone) does not support full-text search.

Text search lacks the following essential properties required by information systems:
Full text indexing allows documents to be preprocessed and an index is saved for later rapid searching. Preprocessing includes:

Dictionaries allow fine-grained control over how tokens are normalized. With appropriate dictionaries, you can define stop words that should not be indexed.

A data type tsvector is provided for storing preprocessed documents, along with a type tsquery for storing query conditions. For details, see Text Search Types. For details about the functions and operators provided for the tsvector data type, see Text Search Functions and Operators. The matching operator @@ is the most important. For details, see Basic Text Matching.