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

Sorting Variable length file with SYNCSORT


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

New User


Joined: 15 Apr 2005
Posts: 8

PostPosted: Tue Dec 05, 2006 7:30 pm
Reply with quote

I have Variable length file. I need to find the following:

Format
01 Record.
10 Init-data PIC X(10).
10 Variable-CTR PIC 9(4) comp-3.
10 Detail-data OCCURS 0 to 100 TIMES depending on Variable-CTR
15 DATE.
20 Date-CC PIC XX.
20 Date-YY PIC XX.
20 FILLER PIC X.
20 Date-MM PIC XX.
20 FILLER PIC X.
20 Date-DD PIC XX.

a) Records with Date = blank or Zeroes
b) Records with Date > Current Date + 29 days.

Can this done with Syncsort ?
Back to top
View user's profile Send private message
William Thompson

Global Moderator


Joined: 18 Nov 2006
Posts: 3156
Location: Tucson AZ

PostPosted: Tue Dec 05, 2006 7:47 pm
Reply with quote

pvsuji4,

Which of the 0 to 100 dates do you wish to sort on?
Back to top
View user's profile Send private message
saipv

New User


Joined: 15 Apr 2005
Posts: 8

PostPosted: Tue Dec 05, 2006 8:00 pm
Reply with quote

I need to SORT the first occurance
Back to top
View user's profile Send private message
saipv

New User


Joined: 15 Apr 2005
Posts: 8

PostPosted: Tue Dec 05, 2006 8:19 pm
Reply with quote

1. I am looking for the first occurance of the DATE value = blank or Zeroes
2. first occurance of DATE > current date + 29 days
Back to top
View user's profile Send private message
saipv

New User


Joined: 15 Apr 2005
Posts: 8

PostPosted: Wed Dec 06, 2006 1:02 am
Reply with quote

hi All,

It's working with the following:

Code:

//SYSIN    DD *                                           
  OPTION VLSHRT NOVLSCMP                             
  SORT FIELDS=COPY                                 
  OUTFIL FILES=01,INCLUDE=(128,18,CH,GT,DATE4+29)   
//*
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 Store the data for fixed length COBOL Programming 1
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