lucene-solr-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Avlesh Singh <avl...@gmail.com>
Subject Re: Problem searching for phrases with the word "to"
Date Mon, 26 Oct 2009 07:46:46 GMT
>
> My guess is that Solr is treating this as a range query.  I've tried
> escaping the word To with backslashes, but it doesn't seem to make a
> difference.  Is there a way to tell Solr that "to" is not a special word in
> this instance?
>
Nope. Any occurrence of "to" in search term(s) does NOT cause the query to
be parsed as a RangeQuery.

You are probably doing phrase search on a "text" field which is analyzed for
stopwords. These stopwords are typically stored in a file called
"stopwords.txt". Make sure your that the stopword analyzer is applied both
at index time and query time.

Cheers
Avlesh

On Mon, Oct 26, 2009 at 12:55 PM, mike mulvaney <mike.mulvaney@gmail.com>wrote:

> I'm having trouble searching for phrases that have the word "to" in
> them.  I have a bunch of articles indexed, and I need to be able to
> search the headlines like this:
>
> headline:"House Committee Leaders Ask FCC To Consider Spectrum in
> Broadband Plan"
>
> When I search like that, I get no hits.  When I take out the word
> "To", it finds the document:
>
> headline:"House Committee Leaders Ask FCC"
>
> My guess is that Solr is treating this as a range query.  I've tried
> escaping the word To with backslashes, but it doesn't seem to make a
> difference.  Is there a way to tell Solr that "to" is not a special
> word in this instance?
>
> -Mike
>

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message