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
 

 

Reformat the file using first 4 records as 1 record

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> DFSORT/ICETOOL
View previous topic :: :: View next topic  
Author Message
Singaiah

New User


Joined: 18 Nov 2008
Posts: 7
Location: Worcester

PostPosted: Mon Dec 15, 2008 10:15 pm    Post subject: Reformat the file using first 4 records as 1 record
Reply with quote

Hi ,

I have a input file with 10 bytes FB length. It has 200 records like below.

0123456789
abcdefghijkl
9876543210
lkjihgfedcba
.....
......
....
1234567890

I need the output file of length of 40 bytes FB length.
First 4 records as 1 record in output file.
Next 4 records as 2 record in output file.

0123456789abcdefghijkl9876543210lkjihgfedcba
.............

Could you please help me on this.

Thanks in advance.
Back to top
View user's profile Send private message

Bill Dennis

Active Member


Joined: 17 Aug 2007
Posts: 562
Location: Iowa, USA

PostPosted: Mon Dec 15, 2008 10:23 pm    Post subject:
Reply with quote

If the BLKSIZE is n*40, the quick and dirty method is to override INPUT LRECL=40 rather than 10 on a copy utility. Output is also LRECL=40.

Four records will be read as one record.
Code:
//SYSUT1 DD DSN=your.file,DISP=OLD,LRECL=40
Back to top
View user's profile Send private message
Skolusu

Senior Member


Joined: 07 Dec 2007
Posts: 2205
Location: San Jose

PostPosted: Mon Dec 15, 2008 10:26 pm    Post subject:
Reply with quote

singaiah,

Check the smart DFSORT trick "Combine multiple records into one record" . It has job for combining four 10 byte records into a 40 byte record:

http://www.ibm.com/systems/support/storage/software/sort/mvs/tricks/
Back to top
View user's profile Send private message
Singaiah

New User


Joined: 18 Nov 2008
Posts: 7
Location: Worcester

PostPosted: Tue Dec 16, 2008 1:12 am    Post subject:
Reply with quote

Thank you so much for your help on this.
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 -> DFSORT/ICETOOL All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts Record Not found in AlX but record re... mukun264 COBOL Programming 0 Fri Mar 24, 2017 9:28 am
No new posts Count the length of the record & ... sreekusr DFSORT/ICETOOL 4 Thu Mar 23, 2017 7:52 pm
No new posts Receive a file using PCOMM macro Harald.v.K IBM Tools 0 Thu Mar 23, 2017 6:50 pm
No new posts Export flat file data into excel sheet murali.andaluri DFSORT/ICETOOL 2 Mon Mar 20, 2017 5:39 pm
No new posts Formatting VB File Learncoholic DFSORT/ICETOOL 3 Mon Mar 20, 2017 12:29 pm


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