View previous topic :: View next topic
|
Author |
Message |
SENTHIL MURUGAAN Warnings : 1 New User
Joined: 12 Jan 2013 Posts: 32 Location: India
|
|
|
|
Hi,
I have list of PS files which will be placed dynamically in a PDS member in previous step.
All the flat files present in PDS(member) must be deleted in the next step and the PDS member file must not be deleted.
PDS : TEST.AAA.FILEPDS(FILES)
the above PDS will hold the below PS Files.
TEST.BBB.TEST1
TEST.ABC.TEST2
TEST.ABC.TEST3
No symbolic qualifiers will be in above file. File naming will be direct and of same record length of 900 in FB format
The number of files available in PDS will vary day to day. So I cannot use simple IEFBR14 step.
Can anyone suggest a sample code, whether this type of deletion is possible through JCL or whether can be achieved using cobol
Thanks,
Senthil |
|
Back to top |
|
|
steve-myers
Active Member
Joined: 30 Nov 2013 Posts: 917 Location: The Universe
|
|
|
|
Write a Rexx exec that reads the member, constructs and executes a TSO DELETE 'data set name' PURGE command for each data set name in the member. |
|
Back to top |
|
|
SENTHIL MURUGAAN Warnings : 1 New User
Joined: 12 Jan 2013 Posts: 32 Location: India
|
|
|
|
Hi Steve,
Thanks for reply. I dont have knowledge on rexx . Can you please share me a sample code. So that I can try on my side.
Thanks,
Senthil |
|
Back to top |
|
|
David Robinson
Active User
Joined: 21 Dec 2011 Posts: 199 Location: UK
|
|
|
|
It's unlikely that Steve will have a Rexx ready that does exactly what YOU want.
You will need to read the manuals, experiment, and come back to the forum if there are any particular points you are not clear on. |
|
Back to top |
|
|
enrico-sorichetti
Superior Member
Joined: 14 Mar 2007 Posts: 10873 Location: italy
|
|
Back to top |
|
|
SENTHIL MURUGAAN Warnings : 1 New User
Joined: 12 Jan 2013 Posts: 32 Location: India
|
|
|
|
Hi enrico,
I used a sort card to concatenate "DELETE" prefixing the file names using INREC and copied the output using IEBGENER to a PDS member and passed it to sysin DD card of IDCAMS and it worked fine.
Thanks,
Senthil |
|
Back to top |
|
|
Bill Woodger
Moderator Emeritus
Joined: 09 Mar 2011 Posts: 7309 Location: Inside the Matrix
|
|
|
|
You don't need the IEBGENER step, SORT can write directly to a PDS member, and anyway a plain sequential dataset can easily be used as input to IDCAMS (a library(pdsmem) is nothing more than a sequential dataset at that level).
If you post your SORT step we can review it, and have a useful example. |
|
Back to top |
|
|
|