The RIGHT() function returns the last n characters of a string. It is useful for extracting the end of a code or an identifier.
Text function name:
RIGHT()
Syntax
RIGHT(text, number_of_characters)ℹ Calling function parameters in TimeTonic:
- $field_name = field (link, linked table column, number, selection, formula, text...).
- "free text" = free text to be added between quotation marks.
- do not use quotation marks for numbers.
Parameters
| Parameter | Description |
|---|---|
text |
Source string. |
number_of_characters |
Number of characters to return from the end (default is 1). |
Example
RIGHT("ABC1234", 4)Result: "1234"
If number_of_characters is 0, an empty string is returned.
Notes
If
number_of_charactersis greater than the length of the text, the entire string is returned.
Return type
The function returns a text string.
The output type format of the result can be configured in the output field options of the formula editor. For more details, see Output format options in the Formula column article.