I have one index with multiple types, each type has a different mapping,
but they share a common geo_point field called location.
How can I query across all types with a geo_distance filter?
It fails to find the location field (QueryParsingException[[myindex] failed
to find geo_point field [location]]; }]").
If I specify a type in the URL
(http://localhost:9200/myindex/mytype/_search) then it works, but if I
specify a type in the geo_distance filter (mytype.location) and leave the
URL as above it finds nothing.
Can you try without the _all option, just myindex/_search? Which version are you using?
On Wednesday, February 15, 2012 at 2:38 PM, Gábor Suhai wrote:
Hi everyone,
I have one index with multiple types, each type has a different mapping, but they share a common geo_point field called location.
How can I query across all types with a geo_distance filter?
It fails to find the location field (QueryParsingException[[myindex] failed to find geo_point field [location]]; }]").
If I specify a type in the URL (http://localhost:9200/myindex/mytype/_search) then it works, but if I specify a type in the geo_distance filter (mytype.location) and leave the URL as above it finds nothing.
Apache, Apache Lucene, Apache Hadoop, Hadoop, HDFS and the yellow elephant
logo are trademarks of the
Apache Software Foundation
in the United States and/or other countries.