Skip to content

Instantly share code, notes, and snippets.

@achton
Last active August 1, 2018 13:41
Show Gist options
  • Save achton/8d47582bddcd97c08a3a45d923f300ca to your computer and use it in GitHub Desktop.
Save achton/8d47582bddcd97c08a3a45d923f300ca to your computer and use it in GitHub Desktop.
Elasticsearch result example for range data - see the "office_postal_from" and "office_postal_to" fields.
{
"took" : 26,
"timed_out" : false,
"_shards" : {
"total" : 5,
"successful" : 5,
"failed" : 0
},
"hits" : {
"total" : 1,
"max_score" : 3.1368427,
"hits" : [
{
"_index" : "elasticsearch_index_office_index",
"_type" : "office_index",
"_id" : "entity:node/46:da",
"_score" : 3.1368427,
"_source" : {
"address_postal_code" : [
"1850"
],
"address_town" : [
"Frederiksberg C"
],
"id" : [
"46"
],
"office_postal_from" : [
"1500",
"1800",
"2000"
],
"office_postal_to" : [
"1799",
"1999",
"2000"
]
}
}
]
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment