Joined: 26 Nov 2002 Posts: 12401 Topics: 75 Location: San Jose
Posted: Thu Jun 26, 2008 5:33 pm Post subject:
tlhceh,
Assuming that you are running the same job as OP, change the CTL2CNTL to the following.Look at the the OUTREC BUILD statement which builds current date and yesterday's date in ccyy-mm-dd format
someone else highjacked the thread to ask a similar question for which you provided a slightly different example. I have tried to put DATE1(-) in the header1 line but I get syntax error and I can not find an example of this in the links to manuals.
Thanks for any assistance you provide.
Joined: 21 Nov 2006 Posts: 6 Topics: 1 Location: Central Illinois
Posted: Fri Jun 27, 2008 12:23 pm Post subject:
Kolusu
That works great! Thanks you for your assistance. I now need to read up on the ifthen when options in DFSORT so I can better understand and write these myself. Thanks for the example.
Joined: 21 Nov 2006 Posts: 6 Topics: 1 Location: Central Illinois
Posted: Thu Jul 24, 2008 7:38 pm Post subject:
Kolusu
I sent this to you in a PM but haven't heard back so I thought I might submit to the board for input from others. ....... please don't take that the wrong way I know you are busy and I am just trying to get a solution.
I have discovered what I consider an error in the processing of comparing yesterday file to today's file. If a record exists in yesterday's file but not todays it is being sent to the newly added file. It should not be considered new. I did not think of this situation before. It should be sent to a third file of canceled records. Here is code we are utilizing at this time:
What I expect from here is the following:
record 312456789 should be in the changed file
record 412356789 should be in the new file
record 213456789 should be in a new file called canceled file as it was in yesterdays file but not in todays file. This record currently shows up in the new file and will cause processing issues.
record 123456789 should not be reported in any file as it was the same in both yesterdays file and todays file.
I hope I have explained this thoroughly enough and I apologize for not thinking of this scenario earlier. I know I can, in a separate step, identify the problem record 213456789 but the problem is it can not show up in the new file. How would you suggest to solve this issue?
Thanks in advance for any help.
I have tried to put in a step prior to eliminate the canceled records with the intention of of making a separate report of canceled records with the following code and for some reason it is not picking out the records from yesterdays file that are not in today's file. Here is code I tried:
I would still like to be able to create both reports (canceled and changed) and the new file all in one step but I can see that is a lot of processing for one step.
Joined: 26 Nov 2002 Posts: 12401 Topics: 75 Location: San Jose
Posted: Fri Jul 25, 2008 11:26 am Post subject:
tlhceh,
Sorry busy with work and couldnt' respond to your private message . The following DFSORT/ICETOOL job will give you the desired results. We just need an additional pass to identify the data if it is from yesterday or today. So I added 2 copy operators to copy the files with the indicators. If you can create the files with the indicators then you can skip the first 2 steps. Make sure to have DISP=MOD for T1 temp dataset
Joined: 21 Nov 2006 Posts: 6 Topics: 1 Location: Central Illinois
Posted: Fri Jul 25, 2008 2:37 pm Post subject:
Kolusu
No need to apologize for being busy with work. I understand. I almost had the job figured out by adding a step prior to the icetool step you had given me. But I like the fact that this is completed in one ice tool step. I am unable to create the records with indicators at the end so I will need to leave the first two steps in place. I thank you very much for your assistance regarding this process. I am now trying to convert the canceled file into a report just as the changed report. We will see how that goes.
All times are GMT - 5 Hours Goto page Previous1, 2
Page 2 of 2
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