Hi Sreenivas,
If you go extreme and accept that you want to return even if slop is large, you 
could utilize edismax: use mm to define how much terms must match and pf and ps 
and pf2/3 and ps2/3 to boost results that match slop requirements. Maybe you 
can see if extending edismax might be simpler option for you if OOTB features 
do not match your case.

HTH,
Emir
--
Monitoring - Log Management - Alerting - Anomaly Detection
Solr & Elasticsearch Consulting Support Training - http://sematext.com/



> On 19 Dec 2017, at 04:41, Sreenivas.T <sree...@gmail.com> wrote:
> 
> Hi,
> 
> I'm writing span query with in own custom query parser. I get the tokens
> from query analyzer and create span term queries from each token. Later I'm
> doing span near query with all these span term queries.
> 
> This would work if all the tokens are present in the index with in
> specified slop. However if One of them missing no results comes up. I know
> it is kind of phrase query.
> 
> Is there a way to write span queries to ignore few tokens? I would like to
> return results even if few tokens are present. Please suggest.
> 
> Regards,
> Sreenivas

  • Span queries Sreenivas.T
    • Re: Span queries Emir Arnautović

Reply via email to