Portal | Manuals | References | Downloads | Info | Programs | JCLs | Mainframe wiki | Quick Ref
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Profile Log in to check your private messages Log in
 
Append data from a PS file to another file using SORT

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

New User


Joined: 03 Feb 2010
Posts: 29
Location: Chennai

PostPosted: Fri Aug 17, 2012 9:04 am    Post subject: Append data from a PS file to another file using SORT
Reply with quote

Hi,

There is a PS file FILE1 with LRECL 80 bytes. It has the below data

Code:
ABCDEFG.TXT                                                   
There is another PS file FILE2 with LRECL 80 bytes. It has the below data
Code:

cd AAAAAAAAA                                                     
cd BBBBBBBB                                                     
cd CCCCCC                                                       
cd DDD                                                           
cd EEEEE                                                         
cd FFF                                                           
locsite pri=5 cy sec=1 cy u=testda rec=fb lr=1402 blocksi=0     
get                                                        +     
'USER.NONX.USER1234.SAMPLE(+1)'                                 
quit                                                             


The data from FILE1 needs to be moved after 'get' in FILE2. So the final output needs to be as below

Code:
cd AAAAAAAAA                                                     
cd BBBBBBBB                                                     
cd CCCCCC                                                       
cd DDD                                                           
cd EEEEE                                                         
cd FFF                                                           
locsite pri=5 cy sec=1 cy u=testda rec=fb lr=1402 blocksi=0     
get ABCDEFG.TXT                                            +     
'USER.NONX.USER1234.SAMPLE(+1)'                                 
quit                                                             


Please help to do this using sort or icetool
Back to top
View user's profile Send private message

Pandora-Box

Moderator


Joined: 07 Sep 2006
Posts: 1544
Location: Andromeda Galaxy

PostPosted: Fri Aug 17, 2012 10:03 am    Post subject:
Reply with quote

So you never said your requirement clearly and did a duplicate post?

IF your version of SYNCSORT does support SYMNAMES create a symbol like

FNAME,C'ABCDEFG.TXT'

With this value in SYMNAMES dataset overlay with this data when therecord is get

Should be achievable in two steps
Back to top
View user's profile Send private message
Anuj Dhawan

Senior Member


Joined: 22 Apr 2006
Posts: 6258
Location: Mumbai, India

PostPosted: Fri Aug 17, 2012 11:28 am    Post subject:
Reply with quote

Is not it duplicate of http://www.ibmmainframes.com/viewtopic.php?t=59189&start=30 ?
Back to top
View user's profile Send private message
mksranjani

New User


Joined: 03 Feb 2010
Posts: 29
Location: Chennai

PostPosted: Fri Aug 17, 2012 11:33 am    Post subject:
Reply with quote

There is a difference in the input between the 2 topics.
But it is related. Thanks. I would use the other solution provided.
Back to top
View user's profile Send private message
Anuj Dhawan

Senior Member


Joined: 22 Apr 2006
Posts: 6258
Location: Mumbai, India

PostPosted: Fri Aug 17, 2012 12:10 pm    Post subject:
Reply with quote

Hope you'll get it going now. Thanks for the follow-up, this helps to keep the thing in sync...
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 IDCAMS RENAMING VSAM FILE ALONG WITH ... upendrasri JCL & VSAM 11 Tue Apr 17, 2018 10:42 pm
No new posts 3270 Data stream error Benchwarmer CICS 4 Tue Apr 17, 2018 12:06 am
No new posts How to list data set names with diffe... murali.andaluri CLIST & REXX 8 Thu Apr 12, 2018 11:33 pm
No new posts VSAM file NOT Found error while proce... SumaReva CICS 5 Wed Apr 11, 2018 9:54 pm
No new posts converting a mainframe file with ASA ... Lynne Schuler All Other Mainframe Topics 5 Wed Apr 04, 2018 9:44 am

Facebook
Back to Top
 
Job Vacancies | Forum Rules | Bookmarks | Subscriptions | FAQ | Polls | Contact Us