Macros for SAS Application Developers
https://github.com/sasjs/core
Loading...
Searching...
No Matches
mf_isint.sas File Reference

Returns 1 if the variable contains only digits 0-9, else 0. More...

Go to the source code of this file.

Detailed Description

Note that numerics containing any punctuation (including decimals or exponents) will be flagged zero.

If you'd like support for this, then do raise an issue (or even better, a pull request!)

Usage:

%put %mf_isint(1) returns 1;
%put %mf_isint(1.1) returns 0;
%put %mf_isint(%str(1,1)) returns 0;
Parameters
[in]arginput value to check
Version
9.2

Definition in file mf_isint.sas.