Reference Guide > S Routines > STR_IS_NUM Function
  

STR_IS_NUM Function
Determines if a string contains a numerical value.
Usage
result = STR_IS_NUM(str)
Input Parameters
strA string or an array of strings to check for numerical characters.
Returned Value
If str represents a floating point or integer value, 1 (true), otherwise 0 (false). If str is an array, the returned value will also be an array where result(i) corresponds to str(i).
Keywords
IntegerIf set and nonzero, returned value is true only for integer values, not floating point values. The default is to succeed for floating point or integer values.
Restrictions
Can not deal with a string containing multiple numbers (these test false)—Use the STRSPLIT function or something similar to break these into a string array.
Does not detect integers of the form xxxI, xxxL, or xxxB, or valid forms of Hex or Octal values. Spaces and tab characters are allowed (surrounding a valid number).
See Also
STRSPLIT

Version 2017.0
Copyright © 2017, Rogue Wave Software, Inc. All Rights Reserved.