Page 1 of 1

omite change for lines

PostPosted: Wed Feb 29, 2012 12:08 pm
by sjrcreation
hi ,
need a help here.. i got an answer in sort but my file is a PDS, which has the record as below. sort can t able to handle PDS so can we do in fileaid for the below req. Thanks in advance.
i have a file like (member of a PDS)

d00124 g1245 test xxxx
d00124 g1245 main xxxx
d00124 g1245 main xxxx
d00124 g1245 main xxxx
d00124 g1245 main xxxx

requirement : when i find a text : "Test" then i need to change 4th line char ..

o/P:
d00124 g1245 test xxxx
d00124 g1245 main xxxx
d00124 g1245 main xxxx
d00124 g1245 main xxxx
d11111 g1245 main xxxx

Re: omite change for lines

PostPosted: Wed Feb 29, 2012 12:29 pm
by NicC
Of course DFSORT, and other sorts, can process a member of a PDS - severeal members if they are concatenated e,g,
//SORTIN  DD DSN=MY.PDS(MEM1),DISP=SHR
//        DD DSN=MY.PDS(MEMZ),DISP=SHR
//        DD DSN=MY.PDS(MEM6),DISP=SHR

Re: omite change for lines

PostPosted: Wed Feb 29, 2012 4:30 pm
by sjrcreation
hi Nic,
Thanks for the reply, i too know DD Concatenate but the input member will vary .. ie no of member will differ so cant hard code it in jcl.
this is y i want to try in other utility.. :(

Re: omite change for lines

PostPosted: Wed Feb 29, 2012 5:48 pm
by enrico-sorichetti
I guess that only <sort> and friends have the clauses/construct for such a task out of the box

for any other product You will have to do some programming

how comfortable are You with ISPF services and ISPF EDIT macro services and REXX

will an <ad hoc> REXX script using ISPF services pass the acceptance process of YOur organization

Re: omite change for lines

PostPosted: Wed Feb 29, 2012 6:28 pm
by sjrcreation
yes Enrico,
i do rexx prog.

Re: omite change for lines

PostPosted: Wed Feb 29, 2012 7:01 pm
by enrico-sorichetti
see here for an edit macro to apply another edit macro to all the member of a pds
http://ibmmainframes.com/about25947.html