Thanks for your reply. I need to OMIT records by comparing the date field (which is of format (mm/dd/yy) in the records with the current date. Since OMIT/ INCLUDE happens before reformating happens, I have to go for two JOB steps.
I step: Reformat the Date field.
II step: OMIT/INCLUDE the records using DATE1-d and again change the date format to original.
Can this be done in a single JOB step?
Can "&Date-d" used for this?
Yes, you can do it in one pass with DFSORT. For example, let's say your input file is RECFM=FB and LRECL=80 and you want to compare a 'mm/dd/yy' date in positions 1-8 of your input records to the current date - 12. You could use the following DFSORT job. You can change it appropriately for other situations.
If you're using DFSORT (ICExxxs messages), you need z/OS DFSORT V1R5 PTF UK90007 or DFSORT R14 PTF UK90006 (April, 2006) in order to use DATE1-12. If you see 'ICE201I E' in //SYSOUT, you have the PTF. Otherwise, you need to ask your System Programmer to install it (it's free). For complete details on all of the new DFSORT and ICETOOL functions available with the April, 2006 PTF, see: