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 con <co...@gmail.com> on 2009/09/30 11:31:45 UTC

Invalid response with search key having numbers


Hi all
I am getting incorrect results when i search with numbers only or string
containing numbers.
when such a search is done, all the results in the index is returned,
irrespective of the search key.
For eg, the phone number field is mapped to TextField. it can contains
values like , 653-23345
also search string like john25, searched against name will show all the
results.

my analyser looks like:

<fieldType name="mytype" class="solr.TextField">
        <analyzer type="index">
            <tokenizer class="solr.LowerCaseTokenizerFactory"/>
			<filter class="solr.WordDelimiterFilterFactory"
                catenateNumbers="1"
			/>	
        </analyzer>
        <analyzer type="query">
            <tokenizer class="solr.LowerCaseTokenizerFactory"/>
			<filter class="solr.WordDelimiterFilterFactory"
                catenateNumbers="1"
			/>
        </analyzer>
     </fieldType>
	 
anything wrong in the analyser? Do i need to use any other filters instead
of catenateAll.

Thanks
C
-- 
View this message in context: http://www.nabble.com/Invalid-response-with-search-key-having-numbers-tp25677793p25677793.html
Sent from the Solr - User mailing list archive at Nabble.com.


Re: Invalid response with search key having numbers

Posted by Shalin Shekhar Mangar <sh...@gmail.com>.
On Wed, Sep 30, 2009 at 3:01 PM, con <co...@gmail.com> wrote:

>
> Hi all
> I am getting incorrect results when i search with numbers only or string
> containing numbers.
> when such a search is done, all the results in the index is returned,
> irrespective of the search key.
> For eg, the phone number field is mapped to TextField. it can contains
> values like , 653-23345
> also search string like john25, searched against name will show all the
> results.
>
>
Getting all results irrespective of the query is very odd. Try adding
debugQuery=on to the queries. That will show you exactly how the query is
being parsed.

-- 
Regards,
Shalin Shekhar Mangar.