lucene-solr-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From vicky desai <vicky.de...@germinait.com>
Subject is phrase search possible in solr
Date Fri, 19 Apr 2013 14:59:03 GMT
I want to do a phrase search in solr without analyzers being applied to it 
eg - If I search for *"DelhiDareDevil"* (i.e - with inverted commas)it
should search the exact text and not apply any analyzers or tokenizers on
this field
However if i search for *DelhiDareDevil* it should use tokenizers and
analyzers and split it to something like this *delhi dare devil*

My schema definition for this is as follows

    <fieldType name="text" class="solr.TextField"
    			positionIncrementGap="100" autoGeneratePhraseQueries="false">
    			<analyzer type="index">
    				<tokenizer class="solr.WhitespaceTokenizerFactory" />
    				<filter class="solr.WordDelimiterFilterFactory"
    					generateWordParts="1" generateNumberParts="1" catenateWords="1"
    					catenateNumbers="1" catenateAll="0" splitOnCaseChange="1"
preserveOriginal="1"/>
    				<filter class="solr.LowerCaseFilterFactory" />
    			</analyzer>
    			<analyzer type="query">
    				<tokenizer class="solr.WhitespaceTokenizerFactory" />
    				<filter class="solr.WordDelimiterFilterFactory"
    					generateWordParts="1" generateNumberParts="1" catenateWords="1"
    					catenateNumbers="1" catenateAll="0" splitOnCaseChange="1"
preserveOriginal="1"/>
    				<filter class="solr.LowerCaseFilter``Factory" />
    			</analyzer>
    		</fieldType>
    
    <field name="cContent" type="text" indexed="true" stored="true"
multiValued="false"/>

any help would be appreciated




--
View this message in context: http://lucene.472066.n3.nabble.com/is-phrase-search-possible-in-solr-tp4057312.html
Sent from the Solr - User mailing list archive at Nabble.com.

Mime
View raw message