Fts
Full-text search examples
Index text before searching it. Choose word matching for required terms, phrase matching for word order, or BM25 for ranked results. Search entries and source rows are updated separately.
Start with Make text searchable, then find the word wireless. That pair needs one document and shows the whole write-to-result flow. Add more documents before comparing ranking scores or grouped totals.
- Index the sample textUse the same table, field and ID in later requests.
- Choose a text questionLook for a word, a phrase or ranked matches.
- Inspect the returned IDsRead scores or summaries only where that request supports them.
Search and summarize text
- Make text searchable — Add a document’s words to a full-text index.
- Find documents containing a word — Search an indexed field for a word.
- Require every query word — Find documents containing all query words, in any order and not necessarily next to each other.
- Find words in order — Match adjacent words in query order after the field’s analyzer has processed them.
- Rank text matches — BM25 ranks documents using term frequency and document length.
- Combine matches from several fields — Search title and description separately, then combine their scores in your application.
- Summarize matching documents — Search text and calculate summaries across its matches, such as counts by category.
- Offer query suggestions — Suggest words or phrases from an indexed field.
- Control equivalent and ignored words — Synonyms represent equivalent words.
Before adapting a recipe
Use a test database, load the named sample data, and check the expected result. Read each page’s limits before changing the query. See connection and SDK notes.