dtSearch Text Retrieval Engine Programmer's Reference
Redefining Search Operators

How to change the operator characters @ # % ~ & : = used in search requests

Use Options.MacroChar, FuzzyChar, PhonicChar, StemmingChar, SynonymChar, WeightChar, and MatchDigitChar to change these symbols from the defaults. The defaults are:

MacroChar @ FuzzyChar % PhonicChar # StemmingChar ~ SynonymChar & WeightChar : MatchDigitChar =

See Search Features for more information on the meaning of each special character. The following special characters in search requests cannot be redefined: * ? ( ) " 

The character specified must be a single-byte punctuation character, in the range from 33 to 127, that is not a searchable letter

You can also set a character to a space to disable the associated feature. For example, if you set SynonymChar to a space, synonym searching will be disabled and the & character can be used for other purposes. 

The operator characters can be changed at search time and do not affect indexing. 


(1) The prefix used to identify regular expressions is a doubling of the PhonicChar (##). 

(2) The mark used to add a field name in front of a word is a doubling of the WeightChar (::) 

(3) The mark used to express ranges is a doubling of the StemmingChar (~~). 

(4) Characters must be single-byte punctuation characters. 

(5) ! cannot be used as the PhonicChar, FuzzyChar, or MatchDigitChar. 

(6) To make email addresses searchable without making numerous punctuation characters searchable letters, see Recognition of Dates, Email Addresses, and Credit Card Numbers.