IBM Mainframe Forum Index
 
Log In
 
IBM Mainframe Forum Index Mainframe: Search IBM Mainframe Forum: FAQ Register
 

Format this file with date as header


IBM Mainframe Forums -> DFSORT/ICETOOL
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
gskn4u
Currently Banned

New User


Joined: 29 Feb 2008
Posts: 25
Location: hyderabad

PostPosted: Sun Jun 29, 2008 12:47 am
Reply with quote

Hi

i have an input file and i want to format this file with date as header and copy the entire file to output. Can anyone provide me the code to this. Date should be current date.


Thanks,
Santosh
Back to top
View user's profile Send private message
Frank Yaeger

DFSORT Developer


Joined: 15 Feb 2005
Posts: 7129
Location: San Jose, CA

PostPosted: Sun Jun 29, 2008 3:12 am
Reply with quote

You could use a DFSORT job like this:

Code:

//S1    EXEC  PGM=ICEMAN
//SYSOUT    DD  SYSOUT=*
//SORTIN DD *
RECORD 1
RECORD 2
/*
//SORTOUT DD SYSOUT=*
//SYSIN    DD    *
   OPTION COPY
   OUTFIL REMOVECC,HEADER1=(DATE=(4MD/))
/*


SORTOUT would have:

Code:

2008/06/28 
RECORD 1   
RECORD 2   


If you want something else, you need to be more specific about what you want.
Back to top
View user's profile Send private message
gskn4u
Currently Banned

New User


Joined: 29 Feb 2008
Posts: 25
Location: hyderabad

PostPosted: Sun Jun 29, 2008 2:06 pm
Reply with quote

Yes. This is what i wanted. This is a part of my requirement. Thanks Frank.


Santosh.
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic View Bookmarks
All times are GMT + 6 Hours
Forum Index -> DFSORT/ICETOOL

 


Similar Topics
Topic Forum Replies
No new posts Compare 2 files and retrive records f... DFSORT/ICETOOL 3
No new posts FTP VB File from Mainframe retaining ... JCL & VSAM 8
No new posts Replacing 'YYMMDD' with date, varying... SYNCSORT 3
No new posts Extract the file name from another fi... DFSORT/ICETOOL 6
No new posts How to split large record length file... DFSORT/ICETOOL 10
Search our Forums:

Back to Top