lucene-solr-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Erick Erickson <erickerick...@gmail.com>
Subject Re: is phrase search possible in solr
Date Mon, 22 Apr 2013 11:18:26 GMT
bq: wherein if I have a query in double quotes it simply ignores all the
tokenizers and analyzers.

Nope. In general you're quite right, you need to re-index whenever you
change your schema... You could define the query part of your field
to just use KeywordTokenizerFactory, but that would affect _all_ queries
which doesn't work for your case..

You might be able to spoof things with, say, the "raw" query parser, see:
http://wiki.apache.org/solr/SolrQuerySyntax
or perhaps the "term" query, but I think you'll have some issues here if you
need to have more than one term next to each other (i.e. phrases). And
you'll have to handle all the upstream bits yourself, e.g. making sure
casing matches.  DelhiDareDevil is indexed as delhidaredevil for instance.

You could write your own query parser that handled this as a special
case, but that would involve quite a lot of work.

Best
Erick

On Mon, Apr 22, 2013 at 1:02 AM, vicky desai <vicky.desai@germinait.com> wrote:
> Hi Jack,
>
> Making a changes in the schema either keyword tokenizer or copy field option
> which u suggested would require reindexing of entire data. Is there an
> option wherein if I have a query in double quotes it simply ignores all the
> tokenizers and analyzers.
>
>
>
> --
> View this message in context: http://lucene.472066.n3.nabble.com/is-phrase-search-possible-in-solr-tp4057312p4057804.html
> Sent from the Solr - User mailing list archive at Nabble.com.

Mime
View raw message