View previous topic :: View next topic
|
Author |
Message |
umasankarmf
New User
Joined: 08 Sep 2008 Posts: 43 Location: india
|
|
|
|
Hi,
I have a requirement like, one dataset has the data with record length 156. Now I want to add current date in the last column for FTP purpose by using JCL.
Can any one please help me.
Thanks in advance |
|
Back to top |
|
|
expat
Global Moderator
Joined: 14 Mar 2007 Posts: 8797 Location: Welsh Wales
|
|
|
|
Why do you need to add the date / time for FTP |
|
Back to top |
|
|
umasankarmf
New User
Joined: 08 Sep 2008 Posts: 43 Location: india
|
|
|
|
Hi expat,
Thanx for the reply. Everyday it will create the dataset. Now client wants that data as report. So he wants the run date in that dataset.
Can you please give me the code for that. |
|
Back to top |
|
|
dbzTHEdinosauer
Global Moderator
Joined: 20 Oct 2006 Posts: 6966 Location: porcelain throne
|
|
|
|
Quote: |
Can you please give me the code for that.
|
Suggest you look at DFSORT. The JCL for this utility could be added as an intermediate Step in your JOB.
Either look thru the posts in the DFSORT forum or refer to the DFSORT references. If you use syncsort, look at the syncsort manuals at your site. |
|
Back to top |
|
|
umasankarmf
New User
Joined: 08 Sep 2008 Posts: 43 Location: india
|
|
|
|
Hi Dick,
Thanks for your reply. Yes you are correct I have to use the intermediate step. Can you tell me that logic. |
|
Back to top |
|
|
umasankarmf
New User
Joined: 08 Sep 2008 Posts: 43 Location: india
|
|
|
|
Hi,
I know how to get the current date. Can any body help me how add that date to the dataset in the last column.
I got the date by using the following jcl.
//PS123 EXEC PGM=ICEMAN
//SYSOUT DD SYSOUT=*
//SORTIN DD *
//SORTOUT DD DSN=B053PXL.DATE.TEST,DISP=SHR
//SYSIN DD *
OPTION COPY
OUTFIL REMOVECC,NODETAIL,
TRAILER1=(DATENS=(MDY))
/* |
|
Back to top |
|
|
Frank Yaeger
DFSORT Developer
Joined: 15 Feb 2005 Posts: 7129 Location: San Jose, CA
|
|
|
|
If you want to add an mmddyy date in positions 151-156 of every record, you can use these DFSORT control statements:
Code: |
OPTION COPY
INREC OVERLAY=(151:DATENS=(MDY))
|
|
|
Back to top |
|
|
umasankarmf
New User
Joined: 08 Sep 2008 Posts: 43 Location: india
|
|
|
|
Hi Frank,
Thanks for your valuable suggestion. Its working fine. But I had done in other way. Any way your code is working. Thanks a lot. |
|
Back to top |
|
|
|