Home | About | Sematext search-lucene.com search-hadoop.com
 Search Lucene and all its subprojects:

Switch to Plain View
Solr, mail # user - Empty results with OR filter query


+
Steven Ou 2012-02-09, 23:42
+
Erik Hatcher 2012-02-10, 00:08
+
Steven Ou 2012-02-10, 00:15
+
Steven Ou 2012-02-10, 00:20
+
Steven Ou 2012-02-10, 00:24
+
Erik Hatcher 2012-02-10, 00:39
+
Steven Ou 2012-02-10, 00:48
+
Steven Ou 2012-02-10, 00:53
+
Steven Ou 2012-02-10, 00:57
+
Erik Hatcher 2012-02-10, 01:01
+
Steven Ou 2012-02-10, 01:11
Copy link to this message
-
Re: Empty results with OR filter query
Erik Hatcher 2012-02-10, 01:14

On Feb 9, 2012, at 20:11 , Steven Ou wrote:

> Sorry, what do you mean "explicit category rather than boolean expression"?

q=category_ids_im:634 for example.  Just to get an idea of what matches each category.

> Type was not changed midstream - hasn't really been changed ever, really.
> And I happen to have *just* reindexed, too.
>
> Don't seem to have a default operator set. Not sure how to do it, either...?

Look at Solr's example schema.xml.  It'll have it spelled out there.

Erik
> --
> Steven Ou | 歐偉凡
>
> *ravn.com* | Chief Technology Officer
> [EMAIL PROTECTED] | +1 909-569-9880
>
>
> On Thu, Feb 9, 2012 at 5:01 PM, Erik Hatcher <[EMAIL PROTECTED]> wrote:
>
>> Extremely odd.
>>
>> Hmmm... other things to try:
>>
>> * query on an explicit category, rather than in a boolean expression
>> * try a different field type than sint (say just int, or string)
>> * shouldn't matter (since you're using "OR" explicitly) but double check
>> the default operator in schema.xml
>> * reindex (was the field type ever changed mid-stream?)
>>
>> Definitely something fishy here.  Nothing obvious pops out yet.
>>
>>       Erik
>>
>>
>> On Feb 9, 2012, at 19:53 , Steven Ou wrote:
>>
>>> Actually, I take that back. Using q instead of fq still produces the same
>>> problem. Somehow it's *less* inconsistent so at first glance it looked
>> like
>>> it fixed it. However, it does *not* fix it :(
>>> --
>>> Steven Ou | 歐偉凡
>>>
>>> *ravn.com* | Chief Technology Officer
>>> [EMAIL PROTECTED] | +1 909-569-9880
>>>
>>>
>>> On Thu, Feb 9, 2012 at 4:48 PM, Steven Ou <[EMAIL PROTECTED]> wrote:
>>>
>>>> Well, keeping all other filter queries the same, changing fq>>>> category_ids_im:(637+OR+639) to fq=category_ids_im:(637+OR+639+OR+634)
>>>> causes results to not show up.
>>>>
>>>> In fact, I took out *all* other filter queries. And while I wasn't able
>>>> to reproduce it exactly, nonetheless when I added the third category id
>> the
>>>> number of results *went down*. Which is consistently inconsistent, per
>>>> se. Adding an OR cannot, logically, reduce the number of results!
>>>> --
>>>> Steven Ou | 歐偉凡
>>>>
>>>> *ravn.com* | Chief Technology Officer
>>>> [EMAIL PROTECTED] | +1 909-569-9880
>>>>
>>>>
>>>>
>>>> On Thu, Feb 9, 2012 at 4:39 PM, Erik Hatcher <[EMAIL PROTECTED]
>>> wrote:
>>>>
>>>>> Yes, certainly should work fine as a filter query... I was merely
>> trying
>>>>> to eliminate variables from the equation.  You've got several filters
>> and a
>>>>> q=*:* going on below, so it's obviously harder to pinpoint what could
>> be
>>>>> going wrong.  I suggest continuing to eliminate variables here, as more
>>>>> than likely some other filter is causing the documents you think should
>>>>> appear to be filtered out.
>>>>>
>>>>>      Erik
>>>>>
>>>>>
>>>>>
>>>>> On Feb 9, 2012, at 19:24 , Steven Ou wrote:
>>>>>
>>>>>> By turning fq=category_ids_im:(637+OR+639+OR+634) to
>>>>>> q=category_ids_im:(637+OR+639+OR+634)
>>>>>> it appears to produce the correct results. But... that doesn't seem to
>>>>> make
>>>>>> sense to me? Shouldn't it work just fine as a filter query?
>>>>>> --
>>>>>> Steven Ou | 歐偉凡
>>>>>>
>>>>>> *ravn.com* | Chief Technology Officer
>>>>>> [EMAIL PROTECTED] | +1 909-569-9880
>>>>>>
>>>>>>
>>>>>> On Thu, Feb 9, 2012 at 4:20 PM, Steven Ou <[EMAIL PROTECTED]> wrote:
>>>>>>
>>>>>>> I don't really know how to analyze the debug output... Here it is for
>>>>> the
>>>>>>> full query I'm running, which includes other filter queries.
>>>>>>>
>>>>>>> <lst name="debug">
>>>>>>> <str name="rawquerystring">*:*</str>
>>>>>>> <str name="querystring">*:*</str>
>>>>>>> <str name="parsedquery">MatchAllDocsQuery(*:*)</str>
>>>>>>> <str name="parsedquery_toString">*:*</str>
>>>>>>> <lst name="explain"/>
>>>>>>> <str name="QParser">LuceneQParser</str>
>>>>>>> <arr name="filter_queries">
>>>>>>> <str>type:Event</str>
>>>>>>> <str>displayable_b:true</str>
>>>>>>> <str>category_ids_im:(637 OR 639 OR 634)</str>
+
Steven Ou 2012-02-10, 19:08