Joined: 15 Feb 2005 Posts: 7129 Location: San Jose, CA
The INCLUDE statement is processed before the INREC statement. Y'DATE1'-45 is a constant in the form yymmdd but the field you're comparing it to is yy/mm/dd so you won't get a match. You need to reformat the field to yymmdd so you can compare them. You can use INREC with UFF to extract yymmdd from yy/mm/dd and then use OUTFIL INCLUDE to do the compare. OUTFIL is processed after INREC.
I'd show you how to do it, but I'm having trouble matching your INREC to your input data since you say the date starts at 10, but you have 1,11 etc in INREC so I don't know what you want the output to look like.
If you need more help with this, show me an example of your input records with ubb code tags and the expected output with ubb code tags. Tell me the RECFM and LRECL of the input file and the starting position, length and format of each input and output field.
When I compared the output 2009 data (FEAIX120,FEAIX123,FEAIX124 are execluded) is compared successfully and required records (FEAIX121,FEAIX122,FEAIX125) are written into output. As I understood, Y2W window starts from 2009 year.. I think that is the reason it is not comparing the records which are from 2008 and 2007.