MVSFORUMS.com Forum Index MVSFORUMS.com
A Community of and for MVS Professionals
 
 FAQFAQ   SearchSearch   Quick Manuals   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Append data from file1 to file2

 
Post new topic   Reply to topic   printer-friendly view    MVSFORUMS.com Forum Index -> Utilities
View previous topic :: View next topic  
Author Message
sub
Beginner


Joined: 30 Jan 2007
Posts: 20
Topics: 12

PostPosted: Thu May 24, 2007 1:24 pm    Post subject: Append data from file1 to file2 Reply with quote

Hi,
I have 2 files. File1 has only 1 row which has the record header whose record length is 500. File1 is sequential file. File2 has 10000 of records whose record length is 20000. File2 is ESDS with variable length. First 500 characters of File2 is always spaces. I want to merge File1 and File2 such that all the records in File2 has first 500 characters of File1.

For example
File1 (say File1 record length is 16) - has only 1 record
1234545646547654

File2
...........................AAAAAAAAAAA
...........................BBBBBBBBBBBBBBB
...........................CCCCCCCCCCC
...........................DDDDDDDDDDDDDD

Output file: File3 with variable length
1234545646547654AAAAAAAAAAA
1234545646547654BBBBBBBBBBBBBBB
1234545646547654CCCCCCCCCCC
1234545646547654DDDDDDDDDDDDDD

Can someone please help.
Thanks
Sub
Back to top
View user's profile Send private message
kolusu
Site Admin
Site Admin


Joined: 26 Nov 2002
Posts: 12378
Topics: 75
Location: San Jose

PostPosted: Thu May 24, 2007 1:29 pm    Post subject: Reply with quote

sub,

please SEARCH before posting. check this link which explains pulling a value from 1 file and using it in another.

http://www.mvsforums.com/helpboards/viewtopic.php?t=7784&highlight=symbols

Kolusu
_________________
Kolusu
www.linkedin.com/in/kolusu
Back to top
View user's profile Send private message Send e-mail Visit poster's website
sub
Beginner


Joined: 30 Jan 2007
Posts: 20
Topics: 12

PostPosted: Thu May 24, 2007 2:58 pm    Post subject: Reply with quote

Kolusu,

It worked. Thanks for your help.

sub
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic   printer-friendly view    MVSFORUMS.com Forum Index -> Utilities All times are GMT - 5 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


MVSFORUMS
Powered by phpBB © 2001, 2005 phpBB Group