Hi,-
i am trying to understand what this api does and it seems
it decomposes the input string by spaces and OR's them and then
depending on occur field setting the whole OR'ed expression is either
under "+" (i.e,must) or just OR'ed again.
Such as:
input string abc def
occur values are : m
Hi Khurram,
My understanding is that once you add a MUST or FILTER clause to a boolean
query, SHOULD clauses become entirely optional, ie. none of them have to
match the document being returned, unless you also set the "minimum number
should match" property to a value >= 1 on the query.
This doe
# is a required, non-scoring term (Occur.FILTER) - semantically it
functions like Occur.MUST. It looks to me as if the Shehzad's query is
missing a clause, eg based on his description it should look like:
+((+term1:a +term2:b) (+term3:a and +term4:b)) #context:2 4 7 ... 198
I agree w/Tomoko,
Hi Khurram,
Lucene query parser's OR operator or Occur.Should are work as expected
for me, I suspect you could miss some points.
> roughly in lucene
> (+term1:a +term2:b) (+term3:a and +term4:b) #context:2 4 7 ... 198
It does not look like an ordinary lucene query string to me ('#' is
not an ope
Hi,
I have a requirement to replicate following SQL query logic containing OR
condition as
where
((term1=a and term2=b) OR (term3=a and term4=b)) and context in
(2,3,4,5.200)
roughly in lucene
(+term1:a +term2:b) (+term3:a and +term4:b) #context:2 4 7 ... 198
It doesn't seem to me g
Hi,
I'm wondering if you mean Elasticsearch's
org.apache.lucene.search.grouping.CollapsingTopDocsCollector.
Elasticsearch 6.4.0, the latest version, is shipped with this class.
https://github.com/elastic/elasticsearch/tree/v6.4.0/server/src/main/java/org/apache/lucene/search/grouping
I'm not sure
Kevin, the sequence is the following: get terms for the field, get postings
for a term and further get payload from the postings. Have a read a little
about reverse index structure and it will be more clear to you.
Your Query creates Weight, that must create a scorer in the method
scorer(context).