Portal | Manuals | References | Downloads | Info | Programs | JCLs | Master the Mainframes
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Usergroups Profile Log in to check your private messages Log in
 

 

SYNCSORT to retrieve last month's details.

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> JCL & VSAM
View previous topic :: :: View next topic  
Author Message
eytellene

New User


Joined: 19 May 2009
Posts: 16
Location: Philippines

PostPosted: Tue May 26, 2009 2:00 pm    Post subject: SYNCSORT to retrieve last month's details.
Reply with quote

Hi Masters,

I just would like to ask if is it possible in JCL to retrieve to sort records to retrieve last month's details?

example

File 1 has the following details
FB, length - 80
date starts at positin 21 (10 bytes) in mm/dd/yyyy format
xxxxxxxxxxxxxxxxxxxx02/10/2009xxxxxxxxxxx....
xxxxxxxxxxxxxxxxxxxx03/02/2009xxxxxxxxxxx....
xxxxxxxxxxxxxxxxxxxx04/04/2009xxxxxxxxxxx....
xxxxxxxxxxxxxxxxxxxx04/06/2009xxxxxxxxxxx....
xxxxxxxxxxxxxxxxxxxx04/08/2009xxxxxxxxxxx....
xxxxxxxxxxxxxxxxxxxx05/01/2009xxxxxxxxxxx...

Output File must be

xxxxxxxxxxxxxxxxxxxx04/04/2009xxxxxxxxxxx....
xxxxxxxxxxxxxxxxxxxx04/06/2009xxxxxxxxxxx....
xxxxxxxxxxxxxxxxxxxx04/08/2009xxxxxxxxxxx....

will this JCL work?

Code:

//PS020    EXEC PGM=SYNCSORT                               
//SYSOUT   DD  SYSOUT=*                                   
//SORTIN   DD  DSN= input file,
//         DISP=SHR                                   
//SORTOUT  DD  DSN=output file
//         DISP=(,CATLG,DELETE),
//         RECFM=FBA,                                   
//         DATACLAS=STANDARD   
//*
//SYSIN    DD *     
  SORT FIELDS=COPY
  OUTFIL FILES=OUT, 
  INREC OVERLAY=(81:&DATE2)                       
     INCLUDE=(11,02,CH,EQ,86,02,CH,AND,
            17,04,CH,EQ,81,04,CH)
  TRAILER1=(01:'MTD ALL   ',     
            11:COUNT15),
  NODETAIL
/*
Back to top
View user's profile Send private message

Arun Raj

Moderator


Joined: 17 Oct 2006
Posts: 2276
Location: @my desk

PostPosted: Tue May 26, 2009 2:33 pm    Post subject:
Reply with quote

Quote:
will this JCL work?
What happened when u ran this job?
Back to top
View user's profile Send private message
eytellene

New User


Joined: 19 May 2009
Posts: 16
Location: Philippines

PostPosted: Tue May 26, 2009 2:54 pm    Post subject:
Reply with quote

actually that is my problem since I donot have an ID yet and they just want me to design so I am just basing the JCL on the forums and I just want to know if this syntax is correct....or is possible... icon_cry.gif
Back to top
View user's profile Send private message
Arun Raj

Moderator


Joined: 17 Oct 2006
Posts: 2276
Location: @my desk

PostPosted: Tue May 26, 2009 6:26 pm    Post subject:
Reply with quote

Quote:
actually that is my problem since I donot have an ID yet and they just want me to design so I am just basing the JCL on the forums
Hello,

You must not be doing the "design" of your requirement based on what you see in a forum. The above code has some syntax errors. Refer your SyncSort manual and learn the correct syntax. If you dont have one, you can contact Alissa Margulies(JCL Moderator) or send an email to zos_tech@syncsort.com
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> JCL & VSAM All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts SORT to append Month and YEAR in MMYY... tisamf DFSORT/ICETOOL 1 Wed Mar 08, 2017 4:46 pm
No new posts SYNCSORT SEQNUM and FI fields. nartcr SYNCSORT 7 Sat Jan 21, 2017 4:02 am
No new posts Syncsort Help to group fields sudhakarraju SYNCSORT 6 Thu Dec 29, 2016 1:38 am
No new posts syncsort: copy lines after the keyword shreya19 SYNCSORT 7 Fri Dec 02, 2016 9:47 am
No new posts Syncsort - Hard coded Value in output PORYES SYNCSORT 1 Thu Nov 03, 2016 9:23 am


Facebook
Back to Top
 
Mainframe Wiki | Forum Rules | Bookmarks | Subscriptions | FAQ | Tutorials | Contact Us