The limitation of only able to use term queries comes from Lucene. I never
looked into why there is such a limitation in Lucene, but since they have a
lot of smart people working on the code, I assume there must be a good
reason. Phrase queries do not have such a limitation.
I use span queries a lot where I require phrase queries with in order
terms. I pre-analyzed my queries by instantiating an AnalysisService
locally, which is only doable if using the Java API. Hackish, but it works.
Ultimately I need to move away from span queries.
Cheers,
Ivan
On Wed, Jun 4, 2014 at 1:37 PM, Nikolas Everett nik9000@gmail.com wrote:
Is there a way to perform a span_first query against a query_string or
match query? I'd like to use this in a rescore to improve relevance.
If I can't do that I'll have to do something silly like create another
field pre-chopped on the way into Elasticsearch.
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.