This is similar to the Numeric test. Use BI for the format. Use EQ to test for alphanumerics or NE to test for non-alphanumerics. Instead of NUM, use one of the following corresponding to the set of alphanumeric characters you need:

UC: Uppercase characters (A-Z)

LC: Lowercase characters (a-z)

MC: Mixed case characters (A-Z, a-z)

UN: Uppercase and numeric characters (A-Z, 0-9)

LN: Lowercase and numeric characters (a-z, 0-9)

MN: Mixed case and numeric characters (A-Z, a-z, 0-9)

Here is an INCLUDE statement that only includes records which have uppercase or numeric characters in positions 11 to 17:

INCLUDE COND=(11,7,BI,EQ,MN)

If every position from 11 to 17 in a record has A-Z, a-z or 0-9, that record is included. If any position from 11 to 17 in a record does not have A-Z,a-z or 0-9, that record is not included. So a record with ‘RAJESH1’ in 11 to 17 would be included, whereas records with ‘R,ajesh’ would not be included.

This MN option can be used to check for non alphanumeric characters (Special Characters) in the whole record or at a specified position.

——————————————————————————————————–

In United States, If you would like to Earn Free Stocks, Credit card Points and Bank account Bonuses, Please visit My Finance Blog

——————————————————————————————————–

You may also like to look at:

Working on Mainframes – Is Change to a different technology necessary
Important SQL CODES and ABEND CODES
SORT JOIN – TO JOIN TWO FILES BASED ON A KEY
KNOW YOUR MAINFRAME
REXX – INITIAL SETUP
SAS – SAMPLE PROGRAM
SORT – CONVERT PD to ZD IN DISPLAYABLE FORMAT (ZDF)
SORT – Alphanumeric Tests for INCLUDE and OMIT
SORT – EQUALS Option
SORT – PARSE – REFORMAT VARIABLE FIELDS
SORT – FINDREP, IFTHEN and INREC
SORT – JUSTIFY, SQUEEZE and OVERLAY
SORT – LOOKUP AND CHANGE
SORT – CONVERT PD to ZD and BI to ZD
SORT – OUTREC – TRAN
SORT – OUTREC – INSERT ZEROES, BLANKS, STRINGS
SORT – OUTPUT DATASET DCB (LRECL,RECFM,BLKSIZE)
SORT – INCLUDE and OMIT
SORT – Process Order of CONTROL Statements
SORT – How to use VB dataset (VLSHRT)
SORT – EDIT MASK PATTERNS
SORT – EDIT NUMERIC FIELDS (I,T,S)
SORT – EDIT FIRST AND LAST RECORD
SORT – SYMBOLS
SORT – TO REPLACE A CHAR WITH ANOTHER CHAR – ALTSEQ
SORT – SET RETURN CODE ‘04’ IF OUTPUT FILE IS EMPTY
SORT – INREC, INCLUDE and OMIT
SORT – SKIPREC and STOPAFT
SORT – INREC
SORT – SUM FIELDS
SORT – REMOVE DUPLICATES AND WRITE THEM TO XSUM
DFSORT – Informational and Error Messages
SORT JOIN – UNPAIRED RECORDS INDICATOR
SORT JOIN – TO JOIN TWO FILES BASED ON A KEY
SORT JOB – SIMPLE COPY
SORT TIPS

 

Advertisement