lucene-solr-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Adrien RUFFIE <a.ruf...@e-deal.com>
Subject RE: How to do fuzzy search on phrases
Date Wed, 14 Jan 2015 14:19:25 GMT
Tomokoさん、おはようございます。

Can I use ComplexPhraseQueryParser with Core Solr 3.3.0 ?

どうもありがとうございます。
お邪魔しました。

宜しくお願いします。
Bien cordialement,

ルフフィエ アドリエン
Adrien Ruffié
LD : +33 1 73 03 26 40
Tél : +33 1 73 03 29 80

E-DEAL
Innover la Relation Client

-----Message d'origine-----
De : Tomoko Uchida [mailto:tomoko.uchida.1111@gmail.com] 
Envoyé : mercredi 14 janvier 2015 14:31
À : solr-user@lucene.apache.org
Objet : Re: How to do fuzzy search on phrases

Hi,

I suspect you are likely to misunderstand fuzzy search.
You should append "~N" to end of each query term, not whole query string /
phrase.
(You can debug your query and get useful information by specifying
"debugQuery=true" parameter, try it if you have not.)

At first glance, I guess Complex Phrase Query Parser possibly might work
for you... This allows more control over phrase query.
https://cwiki.apache.org/confluence/display/solr/Other+Parsers#OtherParsers-ComplexPhraseQueryParser

Just for your information, I indexed a document that has two fields, id and
title. title field is tokenized by StandardTokenizer.
- id: 1
- title: mist spa

And I issued two phrase queries to Solr, one uses default parser (Standard
Query Paraser) and other uses Complex Phrase Query Parser.
* Query 1
title:"mysty~ spa"    // not hit
* Query 2
{!complexphrase}title:"mysty~ spa"    // hits

I have no idea about performance impact. (you'll need sufficient
performance test.)

Regards,
Tomoko



2015-01-14 18:34 GMT+09:00 madhav bahuguna <madhav.bahuguna@gmail.com>:

> HI
>
> Iam using solr 4.7 and solr php client.
>
> So heres the issue ,i have data indexed in solr
> eg
>
> mist spa
>
>
> I have applied fuzzy to my search and If i search myst or mysty i get the
> correct result i get mist spa in result.
> But if i write mysty spa or must spa i do not get ant results.Iam not able
> to implement fuzzy search on more than one word.
> Can any one advise me or help me regarding this.
> The query iam passing using solr php client is
>
> $querynew="(business_name:$data~N)";
>
> --
> Regards
> Madhav Bahuguna
>
Mime
View raw message