Extracts a substring from a character string.
Category: | Character |
Returned data type: | VARCHAR NVARCHAR |
specifies any valid expression that evaluates to a character string. character-string is the source string that is searched for a substring.
Data type | CHAR, VARCHAR, NVARCHAR |
specifies the beginning character position.
Interaction | If position is larger than the length of the source string, FedSQL returns a null value. For example, if you ask for a substring starting at character five but the source string is only four characters long, you get a null result. |
Data type | INTEGER |
specifies the length of the substring to extract.
Interaction | If length is zero, a negative value, or larger than the length of the expression that remains in string after position, FedSQL extracts the remainder of the expression. |
Data type | INTEGER |
Tip | If you omit length, FedSQL extracts the remainder of the expression. |