AnsweredAssumed Answered

How to Query case insensitive in Alfresco Solr search ?

Question asked by devkinandanchauhan on Oct 18, 2018
Latest reply on Oct 22, 2018 by jpotts

Using Alfresco Community - 5.0.0 version.


Below query using Solr returned result :


1st Query : select cmis:objectId from TEST:doc where TEST:docType = 'Type1' 


But we want the case-insensitive search if there are docType value 'type1' || 'TYPE1' || 'tYpe1' || 'Type1' then it should give same number of records.


I've tried below query which works fine while "Trying DB query DbOrIndexSwitchingQueryLanguage" fetch,

but "Using SOLR query DbOrIndexSwitchingQueryLanguage" not returning any result for the same query. 

2nd Query: select cmis:objectId from TEST:doc where LOWER(TEST:docType) = 'type1'


But while using LOWER it's execution time is much higher. For example, if the 1st query takes 10ms then 2nd takes around 3 seconds. 


What is the syntax to search in Solr case insensitive or is there another way to resolve this performance issue?