Method: Substring
Function name: de_substring
Parameter list: (CHAR ColumnName, INTEGER nFrom,INTEGER nSize)
Return type: CHAR
What the method does: Uses position and length references to extract a character substring Return type: from a source string. You specify three parameters:
-
Source column
-
Starting position
-
Length of the substring to be extracted.
For the source string lakeview, if the starting position is 2 and the substring length is 3, the method returns ake.
In case of errors like a source column that has a null or empty-string value, a starting position greater than the length of the source string, or a substring length less than 1, the target column is assigned a null value.