lucene-solr-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Ahmet Arslan <iori...@yahoo.com>
Subject Re: why query chinese character with bracket become phrase query by default?
Date Thu, 05 May 2011 00:50:51 GMT

Please see Robert's two solutions (autoGeneratePhraseQueries or PositionFilter) http://search-lucene.com/m/imED32mqqyp1/

--- On Thu, 5/5/11, cyang2010 <ysxsusan@hotmail.com> wrote:

> From: cyang2010 <ysxsusan@hotmail.com>
> Subject: why query chinese character with bracket become phrase query by default?
> To: solr-user@lucene.apache.org
> Date: Thursday, May 5, 2011, 3:21 AM
> Hi,
> 
> In solr admin query full interface page, the following
> query with english
> become term query according to debug :
> 
> title_en_US: (blood red)
> 
> <lst name="debug">
> <str name="rawquerystring">title_en_US: (blood
> red)</str>
> <str name="querystring">title_en_US: (blood
> red)</str>
> <str name="parsedquery">title_en_US:blood
> title_en_US:red</str>
> <str name="parsedquery_toString">title_en_US:blood
> title_en_US:red</str>
> 
> 
> However, using the same syntax with two chinese terms, the
> query result into
> a phrase query:
> 
> title_zh_CN: (我活)
> 
> <lst name="debug">
> <str name="rawquerystring">title_zh_CN:
> (我活)</str>
> <str name="querystring">title_zh_CN:
> (我活)</str>
> <str name="parsedquery">PhraseQuery(title_zh_CN:"我
> 活")</str>
> <str name="parsedquery_toString">title_zh_CN:"我
> 活"</str>
> 
> 
> I do have different tokenizer/filter for those two
> different fields.   
> title_en_US is using all those common english specific
> tokenizer, while
> title_zh_CN uses
> solr.ChineseTokenizerFactory.   
> 
> I don't think those tokenizer determin whether things
> within bracket become
> term queries or phrase queries.
> 
> I really need to blindly pass user-input text to a solr
> field without doing
> any parsing, and hope it is all doing term query for each
> term contained in
> the search text.
> 
> How do i achieve that?
> 
> Thanks,
> 
> 
> cy
> 
> --
> View this message in context: http://lucene.472066.n3.nabble.com/why-query-chinese-character-with-bracket-become-phrase-query-by-default-tp2901542p2901542.html
> Sent from the Solr - User mailing list archive at
> Nabble.com.
> 

Mime
View raw message