The functions described in this section can extract parts of strings. When used on the left-hand side of the equal sign, the SUBSTR function can also be used to insert characters into specific positions of an existing string.
Purpose: To extract part of a string. When the SUBSTR function is used on the left side of the equal sign, it can place specified characters into an existing string.
Syntax: SUBSTR(character-value, start <,length>)
character-value is any SAS character value.
start is the starting position within the string.
length, if specified, is the number of characters to include in the substring. If this argument is omitted, the SUBSTR function will return all the ...