View previous topic :: View next topic
|
Author |
Message |
sri.mainframes
New User
Joined: 16 Feb 2006 Posts: 29 Location: MUMBAI
|
|
|
|
A file having 10000 variable length records consisting of 100 lrecl, 200 lrecl, 300 lrecl. Now i wanted to copy 100 lrecl into a file , 200 lrecl into another file. can anyone suggest the possible cases to solve this problem
by using cobol and as well as jcl.
regards,
Prince.Sri |
|
Back to top |
|
|
guptae
Moderator
Joined: 14 Oct 2005 Posts: 1208 Location: Bangalore,India
|
|
|
|
Prince,
You just check the first 4 byte value it will give you the length & put the simple evaluate stmt to write it to different o/p file.
01 file-rec.
05 file-length pic s9(4) comp.
05 file-field pic x(1000).
Procedure division.
Evaluate file-length
when 100
write file-a
when 200
write file-b
....
End-evaluate.
Hope it will helpful |
|
Back to top |
|
|
dipanshu
New User
Joined: 16 Jan 2006 Posts: 53 Location: pune
|
|
|
|
Is the above problem can be solve by JCL? |
|
Back to top |
|
|
Hanfur
Active User
Joined: 21 Jun 2006 Posts: 104
|
|
|
|
Hey,
Post this topic in IBM SORT /ICETOOL section;if u want a solution thru JCL..
-Han |
|
Back to top |
|
|
|