I have a sort requirement where in i have to include one condition which is like:
the date format is ddmmyy and dd=13,mm=11,yy=08.
And the need is to get data which has this date field less than or equall to 13 Nov' 2008(131108).
ddmmyy is a packed decimal format with 4 bytes of usage.
But the above condition doesn't satisfy the need as dfsort is considering it as just a no. and not necessarily a date field.
I am aware that there are different formats like full format and year formats.And this comes in YR format.So i used this format and was able to get it done someway which took me to include two JCL sort cards but i hope there is a shortcut method for this.
I will appreciate your views on this.And let me know if you need more clarification.
DFSORT has Y2x formats that can handle mmddyy dates, but not ddmmyy dates so you need to be a bit trickier here.
Here's a DFSORT job that will do what you asked for. I assumed you only have 20yy dates, not 19yy and 20yy dates. I also assumed your input file has RECFM=FB and LRECL=80, but the job can be changed appropriately for other attributes.