replace
|
The replace function replaces a specified number of characters in a
Text or String with another Text or String. The replace function is
non-destructive
Usage The replace function replaces only the substring at the specified index.
The replace function is similar to the substitute function, except
that substitute can replace any or all of the occurrences of the specified
substring whereas replace only replaces one at a specified position in the
String.
(replace old-text start length new-text) The result string after the replace has been done
Expression:
Arguments
Name
Type
Description Argument: old-text String or Text
A String object or Text that contains the text to be replaced. Argument: start Integer
A positive integer indicating the position of the first character in old-text to be replaced.
Set start to 0 for the first character, 1 for the second and so on Argument: length Integer
A positive integer representing the number of characters, after the starting
position, to be replaced. Argument: new-text String or Text
The Text or String to be inserted in old-text at start, replacing the
specified characters. new-text does not have to be the same length as length
Returns:
Here are a number of links to Lambda coding examples which contain this instruction in various use cases.
Here are the links to the data types of the function arguments.
String | Text | Integer |
Here are also a number of links to functions having arguments with any of these data types.
Analytic Information Server (AIS)AIS Component Systems
|