Skip to content

Range datatype documentation should include term query example #27030

@davidbkemp

Description

@davidbkemp

I love the fact that there is now a range datatype, but the documentation on how to use it could possibly be improved by explaining that range datatype fields can be matched against using term queries.

The example on
https://www.elastic.co/guide/en/elasticsearch/reference/current/range.html
could be extended with another query like the following:

GET /range_index/my_type/_search
{
  "query": {
    "term": {
      "expected_attendees": {
        "value": "12"
      }
    }
  }
}

The documentation for Term Query could also be updated to indicate that they can be used to match against range datatype fields.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions