kolchfa-aws 88d06e13bd
Add full-text query documentation (#5428)
* Refactor full-text query documentation

Signed-off-by: Fanit Kolchina <kolchfa@amazon.com>

* Add examples and parameter descriptions

Signed-off-by: Fanit Kolchina <kolchfa@amazon.com>

* Add multi-match query

Signed-off-by: Fanit Kolchina <kolchfa@amazon.com>

* Add query string field format

Signed-off-by: Fanit Kolchina <kolchfa@amazon.com>

* Query string examples

Signed-off-by: Fanit Kolchina <kolchfa@amazon.com>

* Add regular expressions and fuzziness

Signed-off-by: Fanit Kolchina <kolchfa@amazon.com>

* Add wildcard and regex warning

Signed-off-by: Fanit Kolchina <kolchfa@amazon.com>

* Added more query string format

Signed-off-by: Fanit Kolchina <kolchfa@amazon.com>

* Added multi-field sections

Signed-off-by: Fanit Kolchina <kolchfa@amazon.com>

* Rewrite minimum should match section

Signed-off-by: Fanit Kolchina <kolchfa@amazon.com>

* Added allow expensive queries section

Signed-off-by: Fanit Kolchina <kolchfa@amazon.com>

* Add simple query string query

Signed-off-by: Fanit Kolchina <kolchfa@amazon.com>

* Small rewrites

Signed-off-by: Fanit Kolchina <kolchfa@amazon.com>

* Add intervals query

Signed-off-by: Fanit Kolchina <kolchfa@amazon.com>

* Include discover in query string syntax

Signed-off-by: Fanit Kolchina <kolchfa@amazon.com>

* Link and index page fix

Signed-off-by: Fanit Kolchina <kolchfa@amazon.com>

* Apply suggestions from code review

Co-authored-by: Melissa Vagi <vagimeli@amazon.com>
Signed-off-by: kolchfa-aws <105444904+kolchfa-aws@users.noreply.github.com>

* Implemented editorial comments

Signed-off-by: Fanit Kolchina <kolchfa@amazon.com>

---------

Signed-off-by: Fanit Kolchina <kolchfa@amazon.com>
Signed-off-by: kolchfa-aws <105444904+kolchfa-aws@users.noreply.github.com>
Co-authored-by: Melissa Vagi <vagimeli@amazon.com>
2023-11-01 09:29:13 -04:00

2.5 KiB

layout title has_children has_toc nav_order redirect_from
default Full-text queries true false 30
/opensearch/query-dsl/full-text/
/opensearch/query-dsl/full-text/index/
/query-dsl/query-dsl/full-text/
/query-dsl/full-text/

Full-text queries

This page lists all full-text query types and common options. There are many optional fields that you can use to create subtle search behaviors, so we recommend that you test out some basic query types against representative indexes and verify the output before you perform more advanced or complex searches with multiple options.

OpenSearch uses the Apache Lucene search library, which provides highly efficient data structures and algorithms for ingesting, indexing, searching, and aggregating data.

To learn more about search query classes, see Lucene query JavaDocs.

The full-text query types shown in this section use the standard analyzer, which analyzes text automatically when the query is submitted.

The following table lists all full-text query types.

Query type Description
intervals Allows fine-grained control of the matching terms' proximity and order.
match The default full-text query, which can be used for fuzzy matching and phrase or proximity searches.
match_bool_prefix Creates a Boolean query that matches all terms in any position, treating the last term as a prefix.
match_phrase Similar to the match query but matches a whole phrase up to a configurable slop.
match_phrase_prefix Similar to the match_phrase query but matches terms as a whole phrase, treating the last term as a prefix.
multi_match Similar to the match query but is used on multiple fields.
query_string Uses a strict syntax to specify Boolean conditions and multi-field search within a single query string.
simple_query_string A simpler, less strict version of query_string query.