SUFFIX
- Last Updated: January 17, 2024
- 1 minute read
- OpenEdge
- Version 12.8
- Documentation
Returns the substring of a character string
starting after the position specified by start_pos and
the second char_expression, to the end of the string.
Syntax
|
Parameters
- char_expression
-
Evaluates to a character string, typically a character‑string literal or column name. If the expression evaluates to
NULL,SUFFIXreturnsNULL. - start_pos
-
Evaluates to an integer value.
SUFFIXsearches the string specified in the first argument starting at that position. A value of1indicates the first character of the string. - char_expression
-
Evaluates to a single character.
SUFFIXreturns the substring that begins with that character. IfSUFFIXdoes not find the character after start_pos, it returnsNULL. If the expression evaluates to more than one character,SUFFIXignores all but the first character.
Notes
Each char_expression and the result can contain multi‑byte characters. The start_pos argument specifies the character position, not a byte position. Character comparisons are case sensitive and are determined by sort weights in the collation table in the database.
Example
This
example illustrates two ways to use the SUFFIX function:
|
Compatibility
Progress extension