How do you set a Search and Replace rule to be case insensitive?

Currently my Search and Replace rules are case sensitive when running against a case insensitive database.


  • Hi @Robb_Keller

    Thank you for your post - can I possibly get more information on this, please? 
    Which sub-rules are you using within the search-replace rule? Are you using a dictionary lookup, regular expression etc.? What are you trying to achieve with this rule and what type of information are you masking?

    The reason I ask these questions is that there may be a better way to achieve what you're trying to do and failing that I can speak with the development team about this, but would need some more specifics.

    Thank you very much!
  • dOCTOClone,

    I'm using Regex Replace operation.  The Regular Expression for search is case sensitive.  The database is not, with collation set to SQL_Latin1_General_CP1_CI_AS. Replacing with values from dataset 'Text, user Specified', replacing the expression with 'Text to use in rule'.

    Any help is appreciated.

  • Thank you @Robb_Keller - the additional information is helpful!

    I have just checked with the development team to check if this is a feature request we can add in to help, or whether there is some setting that neither of us has caught - I'll come back to you ASAP once I have the answer!
  • Hi @Robb_Keller

    I've just heard back from the Dev team and they have let me know that if you prefix your RegEx with (?i) this should make it case insensitive.
    i.e. (?i)dOCTOClone

    Let me know if you have any other questions - thank you very much.
  • Putting (?i) at the start of the Regular Expression for search worked to replace the expression without case sensitivity.

    Thanks a bunch,
Sign In or Register to comment.