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
 

 

Change the String in input file.

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> CLIST & REXX
View previous topic :: :: View next topic  
Author Message
callkris_cit

New User


Joined: 22 Apr 2006
Posts: 44

PostPosted: Thu Sep 21, 2006 12:36 pm    Post subject: Change the String in input file.
Reply with quote

Hi All,

I want to change one string in the Input file (SAY CATXXX.FILE1)

For example CATXXX.FILE1 contents is as below:

SURESHRAJESH
AAAAAAAAAAA
BBBBBBBBBBB

My requirement is if the value of the String is SURESH, then it should be changed to RAMESH.

After executing REXX program the output would be as below

RAMESHRAJESH
AAAAAAAAAAA
BBBBBBBBBBB

Please provide the Sample rexx code to do this requirement.

Thanks
Suresh
Back to top
View user's profile Send private message

ofer71

Global Moderator


Joined: 27 Dec 2005
Posts: 2360
Location: Israel

PostPosted: Thu Sep 21, 2006 12:49 pm    Post subject:
Reply with quote

If the file is not too big, you can use a one-statement edit-macro "CHANGE ALL SURESH RAMESH".

For bigger files, you will need to read the files using EXECIO or the ISPF service LMMGET, and then do your own processing (OVERLAY, SUBSTR, TRANSLATE etc.).

O.
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 -> CLIST & REXX All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts SORTJOIN - Copy Matched and Unmatched... Steve Ironmonger DFSORT/ICETOOL 5 Tue Jan 17, 2017 4:26 pm
No new posts Copy RECFM =VB TO FB file with RECL =... sahil41352 DFSORT/ICETOOL 3 Wed Dec 28, 2016 11:29 pm
No new posts Performing arithmetic on input field zh_lad DFSORT/ICETOOL 31 Tue Dec 06, 2016 8:04 pm
No new posts High CPU consumption Job using IAM fi... aswinir JCL & VSAM 15 Thu Dec 01, 2016 8:28 pm
No new posts Add PD field from 2nd file to PD in 1st Sushant Garje DFSORT/ICETOOL 6 Thu Dec 01, 2016 4:32 pm


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