lucene-solr-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Lance Norskog <goks...@gmail.com>
Subject Re: Behavior of filter query
Date Fri, 04 Dec 2009 01:08:59 GMT
The second makes 2 large docsets and ands them together against the
query. The third makes the intersection of the two filter queries, The
third will use the least memory and run the fastest.

The first is the slowest because it has to find each docid and check
it against the filter query docset. I think.

On Thu, Dec 3, 2009 at 1:55 AM, gunjan_versata <gunjangarg1@gmail.com> wrote:
>
>
> Guess I found the problem.. By using fq=%2B bla blo  seems to be fixing the
> problem... Can anyone tell me why is it necessary?
>
> also, which query is the best amongst all?
>
> -Gunjan
>
>
> gunjan_versata wrote:
>>
>> Hi,
>>
>> I am working on SOLR 1.4. And am trying to implement the multi select
>> feature on my site. I dont want the faceting counts but only results. I
>> tried diff variations in my query :
>>
>> They are:
>>
>> http://localhost:8080/solr/select?q=*:*&fq=product_category:Mobiles+%2Bproperty_make:(Nokia%20OR%20Sony-Ericsson)+%2Bproperty_bodyType:(CandyBar%20OR%20Slider)
>> Result : 47
>>
>> http://localhost:8080/solr/select?q=Mobiles&qt=store&fq=property_make:(Nokia%20OR%20Sony-Ericsson)&fq=property_bodyType:(CandyBar%20OR%20Slider)
>> Result : 47
>>
>> http://localhost:8080/solr/select?q=Mobiles&qt=store&fq=property_make:(Nokia%20OR%20Sony-Ericsson)+%2Bproperty_bodyType:(CandyBar%20OR%20Slider)
>> Result : 148
>>
>> Now problem is, on the basis of my knowledge, I expected all three queries
>> to give out the same results. Then, why is 3rd one behaving differently?
>> By the way, in the third query, the result set includes entries which have
>> either of them, ie it is behaving like OR, not AND.
>>
>> Also, if anyone could tell me, performance wise which is the best...
>>
>> For more insight:
>>
>> Schema:
>>
>> <fieldType name="lowercase" class="solr.TextField"
>> positionIncrementGap="100">
>>       <analyzer>
>>         <tokenizer class="solr.KeywordTokenizerFactory"/>
>>         <filter class="solr.LowerCaseFilterFactory" />
>>         <filter class="solr.TrimFilterFactory" />
>>         <filter class="solr.SnowballPorterFilterFactory"
>> language="English" protected="protwords.txt"/>
>>       </analyzer>
>> </fieldType>
>>
>> <field name="family_id" type="string" indexed="true" stored="true"
>> omitNorms="true"/>
>>    <field name="product_category" type="string" indexed="true"
>> stored="true" omitNorms="true" />
>>    <field name="img_url" type="string" indexed="false" stored="true" />
>>    <field name="title" type="text" indexed="true" stored="true" />
>>    <field name="price"  type="float" stored="true"/>
>>    <field name="sdp_url" type="string" indexed="false" stored="true" />
>>    <field name="inStock" type="boolean" indexed="true" stored="false" />
>>    <field name="property_keywords" type="string" stored="false"
>> indexed="true" multiValued="true"/>
>>    <field name="property_features" type="string" stored="true"
>> indexed="true" multiValued="true"/>
>>    <dynamicField name="property_*" type="string" stored="true"
>> indexed="true"/>
>>
>> <field name="text" type="lowercase" indexed="true" stored="false"
>> multiValued="true"/>
>> <copyField source="property_*" dest="text"/>
>>
>>
>> Handler:
>>
>>   <requestHandler name="store" class="solr.SearchHandler" >
>>     <lst name="defaults">
>>      <str name="defType">dismax</str>
>>      <str name="echoParams">explicit</str>
>>      <str name="qf">
>>         product_category
>>      </str>
>>      <str name="mm">100%</str>
>>     </lst>
>>     <lst name="appends">
>>       <str name="fq">inStock:true</str>
>>     </lst>
>>   </requestHandler>
>>
>> I am looking out for a quick response. Any kind of help would be highly
>> appreciated.
>>
>> Regards,
>>
>> Gunjan
>>
>
> --
> View this message in context: http://old.nabble.com/Behavior-of-filter-query-tp26623237p26623470.html
> Sent from the Solr - User mailing list archive at Nabble.com.
>
>



-- 
Lance Norskog
goksron@gmail.com

Mime
View raw message