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
 
Change of Char by using JCL.

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

New User


Joined: 14 Sep 2005
Posts: 18

PostPosted: Wed Aug 30, 2006 3:08 pm    Post subject: Change of Char by using JCL.
Reply with quote

Hi All,
I have a sequential file. I want to repalce char. appearing at 5th, 20th & 30th position by 'N', 'Y', 'A'. I DONT want to do this by writing COBOL Pgm. want to do by JCL only. Please suggest how to go for it.

Thanx
Rgds

Vineet
Back to top
View user's profile Send private message

Dariusz
Warnings : 1

New User


Joined: 11 Aug 2005
Posts: 27
Location: POLAND

PostPosted: Wed Aug 30, 2006 4:09 pm    Post subject: Details.
Reply with quote

Hi.
The simple solution it is change command,but I don't know very many questions:
How this file is big ?
Is it FB or VB file ?
Depend on above we can use ISPF EDITOR or CLIST or IEBUPDATE program.
Regards.
Back to top
View user's profile Send private message
IQofaGerbil

Active User


Joined: 05 May 2006
Posts: 183
Location: Scotland

PostPosted: Wed Aug 30, 2006 4:40 pm    Post subject: Re: Change of Char by using JCL.
Reply with quote

Will this do it? (assuming 80 char file here)

Code:

//S1ASORT  EXEC PGM=SORT                                     
//SYSOUT   DD  SYSOUT=X                                       
//SORTIN   DD DSN=MYFILE.SORT1,DISP=SHR                     
//SORTOUT  DD DSN=MYFILE.SORT1,DISP=SHR                     
//SYSIN    DD *                                               
     SORT FIELDS=(COPY)                                 
     OUTREC FIELDS=(1,4,C'Y',6,14,C'N',21,9,C'A',31,50)
Back to top
View user's profile Send private message
Frank Yaeger

DFSORT Moderator


Joined: 15 Feb 2005
Posts: 7130
Location: San Jose, CA

PostPosted: Wed Aug 30, 2006 8:48 pm    Post subject:
Reply with quote

Vineet,

If you want to replace position 5 with 'N', position 20 with 'Y' and position 30 with 'A', you can use the following DFSORT job:

Code:

//S1    EXEC  PGM=ICEMAN
//SYSOUT    DD  SYSOUT=*
//SORTIN DD DSN=...  input file
//SORTOUT DD DSN=...  output file
//SYSIN    DD    *
  OPTION COPY
  INREC OVERLAY=(5:C'N',20:C'Y',30:C'A')
/*
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 Cannot change DATACLAS on DFSMSdss re... Alan Playford JCL & VSAM 10 Tue May 01, 2018 6:43 pm
No new posts Repeat Sequence Number Until change i... rahulabvp DFSORT/ICETOOL 6 Thu Mar 29, 2018 12:51 pm
No new posts How to change the logon screen info o... sakthikumarT TSO/ISPF 4 Fri Dec 29, 2017 6:44 pm
No new posts Change NULL indicator in UNLOAD utility Khadhar Basha DB2 2 Fri Dec 15, 2017 3:01 pm
No new posts Extract record for change in combinat... Trinadh DFSORT/ICETOOL 6 Thu Nov 23, 2017 3:32 pm

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