lucene-solr-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Alexandre Rafalovitch <>
Subject Re: Evaluate function only on subset of documents
Date Tue, 24 Jun 2014 01:20:38 GMT
On Mon, Jun 23, 2014 at 5:02 PM, Costi Muraru <> wrote:
> q=*:*&fq={!cost=1}type:purchase&{!frange u=0 cost=3}mycustomfunction()
> The function is applied on all documents, instead of only those that match
> the *purchase* type. I verified this assumption, by checking the query time
> and also by debugging the custom function.

Not sure the syntax above is correct (is it ...&fq={!frange...}?), but
I wanted to add one bit of information. If you are caching the filter
query (yes, by default), then it applies to the full set of documents.
Because otherwise, it cannot be reused next time. So, if you say
cache=false it should be checked only against the documents matching
the other criteria (based on costs ordering).


Personal website:
Current project: - Accelerating your Solr proficiency

View raw message