This function returns a specific part of a text by using a start index (first element) and end index (last element).


substring(text, startIndex, endIndex) #Output: Text


Take this text as an example:

01234567891011121314151617181920212223
HAMBURGERS
ARE
DELICIOUS


Parser expressionDescription


%{substring("HAMBURGERS ARE DELICIOUS", 11, 14)}


This example returns:

ARE


%{substring("HAMBURGERS ARE DELICIOUS", 15, 24)}


This example returns: 

DELICIOUS



Parameters used in this function

ParameterInput (data type)Description
text

Any given text.
startIndex

A number that specifies the index of the first character for the substring.

The index starts at 0.

In case startIndex is less than 0, an error is returned.

endIndex

A number that specifies the index-1 of the last character for the substring.

The length of the substring is endIndex - startIndex.

In case endIndex is higher than length(text)-1, an error is returned.

In case endIndex - startIndex is less than 0, an error is returned.



This function returns a



Use cases and examples



Short description

Returns a specific part of a text.

Output

Label