Note that there are some explanatory texts on larger screens.

plurals
  1. POHow to create a case insensitive copy of a string field in SOLR?
    primarykey
    data
    text
    <p>How can I create a copy of a string field in case insensitive form? I want to use the typical "string" type and a case insensitive type. The types are defined like so:</p> <pre><code> &lt;fieldType name="string" class="solr.StrField" sortMissingLast="true" omitNorms="true" /&gt; &lt;!-- A Case insensitive version of string type --&gt; &lt;fieldType name="string_ci" class="solr.StrField" sortMissingLast="true" omitNorms="true"&gt; &lt;analyzer type="index"&gt; &lt;tokenizer class="solr.KeywordTokenizerFactory"/&gt; &lt;filter class="solr.LowerCaseFilterFactory" /&gt; &lt;/analyzer&gt; &lt;analyzer type="query"&gt; &lt;tokenizer class="solr.KeywordTokenizerFactory"/&gt; &lt;filter class="solr.LowerCaseFilterFactory" /&gt; &lt;/analyzer&gt; &lt;/fieldType&gt; </code></pre> <p>And an example of the field like so:</p> <pre><code>&lt;field name="destANYStr" type="string" indexed="true" stored="true" multiValued="true" /&gt; &lt;!-- Case insensitive version --&gt; &lt;field name="destANYStrCI" type="string_ci" indexed="true" stored="false" multiValued="true" /&gt; </code></pre> <p>I tried using CopyField like so:</p> <pre><code>&lt;copyField source="destANYStr" dest="destANYStrCI" /&gt; </code></pre> <p>But, apparently CopyField is called on source and dest before any analyzers are invoked, so even though I've specified that dest is case-insensitive through anaylyzers the case of the values copied from source field are preserved.</p> <p>I'm hoping to avoid re-transmitting the value in the field from the client, at record creation time.</p>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload