You are viewing a plain text version of this content. The canonical link for it is here.
Posted to solr-user@lucene.apache.org by Aleksey Gogolev <po...@dev.co.ua> on 2008/10/25 20:00:03 UTC
Query problem related to * symbol
Hello.
I made this query:
http://localhost:8983/solr/select/?q=suggestion:ipod+nano+80*
and response contains the following doc:
-------------------------------------------------------------
<doc>
<str name="id">
04adea06fcfdc939feec63799045076c
</str>
<str name="suggestion">
apple ma045 for ipod 80gb nano
</str>
<date name="timestamp">
2008-10-25T16:50:48.703Z
</date>
</doc>
-------------------------------------------------------------
Then I made this query (the "g" letter is added):
http://localhost:8983/solr/select/?q=suggestion:ipod+nano+80g*
and I expect to see the same doc in response, but response was empty.
In first moment I thought that this strange behaviour is caused by
SynonymFilter, but I checked the type of field "suggestion", and it is
quite simple, and the filter chain doesn't contain SynonymFilter:
--------------------------------------------------------------
<fieldType name="suggestion" class="solr.TextField">
<analyzer type="index">
<tokenizer class="WhitespaceTokenizerFactory" />
<filter class="solr.StopFilterFactory" words="suggestion_stopwords.txt" ignoreCase="true"/>
</analyzer>
<analyzer type="query">
<tokenizer class="WhitespaceTokenizerFactory" />
<filter class="solr.LowerCaseFilterFactory" />
</analyzer>
</fieldType>
--------------------------------------------------------------
Any ideas about reasons of this strange behaviour?
--
Aleksey Gogolev
developer,
dev.co.ua
Aleksey
Re: Query problem related to * symbol
Posted by Yonik Seeley <yo...@apache.org>.
On Sat, Oct 25, 2008 at 2:00 PM, Aleksey Gogolev <po...@dev.co.ua> wrote:
> I made this query:
> http://localhost:8983/solr/select/?q=suggestion:ipod+nano+80*
Note that in Lucene syntax, this query is equivalent to
suggestion:ipod default_field:nano default_field:80*
For debugging, add debugQuery=true to your request to see what the
parsed query looks like.
-Yonik