The
string_extract
function extracts a portion of a string.
● stm_string—Designates the function as a string manipulation function
● extract—Signifies that the function extracts a portion of the input string
● string—The input string
● index—The integer location from which the output string portion starts
● length—The output string length (integer)
● status—One of the following status codes:stm_success
,stm_null_string
,stm_illegal_index
, andstm_illegal_len
stm_string_extract(’ABCDE’,0,2,status) = ’AB’
stm_string_extract(’ABCDE’,3,2,status) = ’DE’
stm_string_extract(’ABCDE’,3,7,status) = ’’
and status = stm_illegal_len