GPS
GPS

Reputation: 31

schema.xml notation for case insensitive text searches in Solr 8.4.1 to be integrated with Java Spring Data Solr libraries

I have created a search Application using Solr storage where in the Data is stored in Solr and queried in Java SolrCrudRepository, but I am not able to create Case Insensitive searches in the Angular Front-end. I could find the below syntax on googling-

enter code here

<fieldType name="advstring" class="solr.TextField">
  <analyzer type="index">       
    <tokenizer class="solr.LowerCaseTokenizerFactory" />
    <filter class="solr.StopFilterFactory" ignoreCase="true" words="stopwords.txt" />
  </analyzer>
  <analyzer type="query">       
    <tokenizer class="solr.LowerCaseTokenizerFactory"/>
    <filter class="solr.StopFilterFactory" ignoreCase="true" words="stopwords.txt" />
  </analyzer>
</fieldType>
<fieldType name="text_general" class="solr.TextField" 
positionIncrementGap="100"  multiValued="true">
  <analyzer type="index">
    <tokenizer class="solr.StandardTokenizerFactory"/>
    <filter class="solr.StopFilterFactory"
   ignoreCase="true" words="stopwords.txt" />                                                                                      
    <filter class="solr.LowerCaseFilterFactory"/>
  </analyzer>
  <analyzer type="query">
    <tokenizer class="solr.StandardTokenizerFactory"/>
    <filter class="solr.StopFilterFactory" ignoreCase="true" words="stopwords.txt" />
    <filter class="solr.SynonymGraphFilterFactory" synonyms="synonyms.txt" ignoreCase="true" expand="true"/>
    <filter class="solr.LowerCaseFilterFactory"/>
  </analyzer>
</fieldType>
enter code here

but with the text_general some fields are not reflecting and only few text fields are reflecting.While advstring type fields are case sensitive in nature.

Upvotes: 0

Views: 49

Answers (0)

Related Questions