Posted: Thu Nov 24, 2005 3:08 am Post subject: Extract only last month data from a GDG
Problem is as follows.
This program/utility will run 7th of every month.What it should do is copy all records of GDG genertions which is having the last month dates as its one of the fields.
Example. GDG record contains a date field.Based on this we have to copy it to another file.Assume that the program runs on DEC 7th.if date field contain 20051123 we have to copy it to another file.if the date is 2001202 discard it.We can do this by comparing '11'(month field).But I want to run this program every month (and it should copy the records containing previous month dates) without changing anything.Can we do this using SORT/ICETOOL utility?
Joined: 02 Dec 2002 Posts: 1618 Topics: 31 Location: San Jose
Posted: Thu Apr 27, 2006 11:43 am Post subject:
With z/OS DFSORT V1R5 PTF UK90007 or DFSORT R14 PTF UK90006 (April, 2006), you can now use DFSORT's new past and future date constant support for this kind of thing. In this case, you can use these DFSORT control statements:
Code:
OPTION COPY
INCLUDE COND=(1,6,ZD,EQ,DATE2P-1)
For complete details on all of the new DFSORT and ICETOOL functions available with the April, 2006 PTFs, see:
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum