Class: MultiMatchQuery

MultiMatchQuery

Constructor

new MultiMatchQuery(query, fields)

Parameters:
Name Type Description
query string

query string

fields Array.<string>

Array of fields to query on.

Source:

Methods

addField(field)

Add provided field to match queries.

Parameters:
Name Type Description
field string

Name of field, wildcards allowed.

Source:

addField(field)

Add provided field to match queries.

Parameters:
Name Type Description
field string

Name of field, wildcards allowed.

Source:

setBoost(boostFactor)

Set query boost.

Parameters:
Name Type Description
boostFactor number

Number, string representation of number, or undefined to unset.

Source:

setBoost(boostFactor)

Set query boost.

Parameters:
Name Type Description
boostFactor number

Number, string representation of number, or undefined to unset.

Source:

setTieBreaker(weight)

Set a tie breaker for the query to reduce the weight of additional matching fields.

Parameters:
Name Type Description
weight Array.<number>

Number between 0 and 1.

Source:

setTieBreaker(weight)

Set a tie breaker for the query to reduce the weight of additional matching fields.

Parameters:
Name Type Description
weight Array.<number>

Number between 0 and 1.

Source:

setType(type)

Set the query type.

Parameters:
Name Type Description
type string

Type of multi_match query. Default is "best_fields"; http://www.elastic.co/guide/en/elasticsearch/reference/1.x/query-dsl-multi-match-query.html#multi-match-types

Source:

setType(type)

Set the query type.

Parameters:
Name Type Description
type string

Type of multi_match query. Default is "best_fields"; http://www.elastic.co/guide/en/elasticsearch/reference/1.x/query-dsl-multi-match-query.html#multi-match-types

Source:

MultiMatchQuery

Constructor

new MultiMatchQuery(query, fields)

Parameters:
Name Type Description
query string

query string

fields Array.<string>

Array of fields to query on.

Source:

Methods

addField(field)

Add provided field to match queries.

Parameters:
Name Type Description
field string

Name of field, wildcards allowed.

Source:

addField(field)

Add provided field to match queries.

Parameters:
Name Type Description
field string

Name of field, wildcards allowed.

Source:

setBoost(boostFactor)

Set query boost.

Parameters:
Name Type Description
boostFactor number

Number, string representation of number, or undefined to unset.

Source:

setBoost(boostFactor)

Set query boost.

Parameters:
Name Type Description
boostFactor number

Number, string representation of number, or undefined to unset.

Source:

setTieBreaker(weight)

Set a tie breaker for the query to reduce the weight of additional matching fields.

Parameters:
Name Type Description
weight Array.<number>

Number between 0 and 1.

Source:

setTieBreaker(weight)

Set a tie breaker for the query to reduce the weight of additional matching fields.

Parameters:
Name Type Description
weight Array.<number>

Number between 0 and 1.

Source:

setType(type)

Set the query type.

Parameters:
Name Type Description
type string

Type of multi_match query. Default is "best_fields"; http://www.elastic.co/guide/en/elasticsearch/reference/1.x/query-dsl-multi-match-query.html#multi-match-types

Source:

setType(type)

Set the query type.

Parameters:
Name Type Description
type string

Type of multi_match query. Default is "best_fields"; http://www.elastic.co/guide/en/elasticsearch/reference/1.x/query-dsl-multi-match-query.html#multi-match-types

Source: