match() function.
Define a collection schema for keyword search
Define a schema with atext() field and add a keyword_index():
Run a keyword search
To run a keyword search on thetitle and description fields using the match() function.
We’ll query the collection to match the term "great" in the title field or the term "novel" in any of the keyword-indexed text fields:
The
match() function will by default execute against all
fields with a keyword index.