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

Syntax needed to pass date thru DSN in Outfil file


IBM Mainframe Forums -> JCL & VSAM
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
shrinivas_3
Warnings : 1

New User


Joined: 05 Sep 2006
Posts: 34

PostPosted: Fri Dec 15, 2006 5:54 pm
Reply with quote

Hi All

I have an input file having date field AT 15th position in I/P file
The code is as below:

Code:

//SORTIN   DD  DSN=i/p file which has date field at 15th position,
//             DISP=SHR                             
//SORTOF01 DD  DSN=o/p file 1 ,           
//             DISP=OLD           
//SORTOF02 DD  DSN=o/p file 2,   
//             DISP=OLD           
//SYSIN    DD  *                                   
   SORT FIELDS=(1,2,BI,A,3,2,BI,A,5,2,BI,A,7,4,BI,A,
                11,2,BI,A,13,2,BI,A,15,10,CH,A)     
  OUTFIL FILES=01,INCLUDE=(15,10,CH,LE,&DATE1(-)+1)
  OUTFIL FILES=02,INCLUDE=(15,10,CH,GT,&DATE1(-)+1)
/*


As of now this syntax works fine .

My requirement is that "Instead of &DATE1 ... i want the DATE to be passed thru a DSN which will have date as '12082006')

Shrinivas
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: Fri Dec 15, 2006 8:53 pm
Reply with quote

You can put the date in a DFSORT Symbols data set:

Code:

//SYMNAMES DD DSN=ds1,...  (FB/80)
...
//SYSIN DD *
  OUTFIL FILES=01,INCLUDE=(15,10,CH,LE,Mydate)
  OUTFIL FILES=02,INCLUDE=(15,10,CH,GT,Mydate)


where ds1 has:

Mydate,'12082006'
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 -> JCL & VSAM

 


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