Altair® Monarch®

 

Function: Replace

Description

Replaces within a given string each instance of a specified substring with a new substring.

Syntax

Replace(string,old,new)

Note: Replacements are case-sensitive. If old is empty then no replacements are made. If new is empty, then instances of old are effectively removed from the string.

Arguments

string is the string that contains the substring you want to replace.

old is the substring to be replaced.

new is the substring to replace old.

Return value

This function returns a character string.

Calculated field example

If a Contact field contained Mary Smith, the following calculated field expression would return Mary Smith-Jones:

Replace(Contact,"Smith","Smith-Jones")

Filter/Find example

Records with a Contact field value of Mary Smith-Jones could be found by the expression:

Replace(Contact,"Smith","Smith-Jones")="Mary Smith-Jones"