ASA SQL Reference
System Procedures and Functions
System extended stored procedures
Other system extended stored procedures
Extracts substrings from an input string and a format string.
[ variable = CALL ] xp_scanf ( in-string, format-string [ output-string ] )
None
xp_scanf extracts substrings from an input string and a format string. The format-string can contain up to fifty string placeholders (%s). The values of these placeholders are placed in the output-string variables.
All arguments must be strings of less than 254 characters.
The following statements put the string World!
into the variable mystring.
CREATE VARIABLE mystring CHAR(254) ; xp_scanf( 'Hello World!', 'Hello %s', mystring )