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
 

 

Delete list of PS files within PDS member

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

New User


Joined: 12 Jan 2013
Posts: 28
Location: India

PostPosted: Thu Apr 09, 2015 12:01 am    Post subject: Delete list of PS files within PDS member
Reply with quote

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
View user's profile Send private message

steve-myers

Active User


Joined: 30 Nov 2013
Posts: 462
Location: The Universe

PostPosted: Thu Apr 09, 2015 12:05 am    Post subject:
Reply with quote

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
View user's profile Send private message
SENTHIL MURUGAAN
Warnings : 1

New User


Joined: 12 Jan 2013
Posts: 28
Location: India

PostPosted: Thu Apr 09, 2015 12:08 pm    Post subject:
Reply with quote

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
View user's profile Send private message
David Robinson

Active User


Joined: 21 Dec 2011
Posts: 175
Location: UK

PostPosted: Thu Apr 09, 2015 12:58 pm    Post subject:
Reply with quote

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
View user's profile Send private message
enrico-sorichetti

Global Moderator


Joined: 14 Mar 2007
Posts: 10203
Location: italy

PostPosted: Thu Apr 09, 2015 1:22 pm    Post subject: Reply to: Delete list of PS files within PDS member
Reply with quote

why not use Your sort product to build the idcams delete statements ???
see here for a example

http://www.ibmmainframes.com/viewtopic.php?t=63190&highlight=sort+idcams+delete
Back to top
View user's profile Send private message
SENTHIL MURUGAAN
Warnings : 1

New User


Joined: 12 Jan 2013
Posts: 28
Location: India

PostPosted: Thu Apr 09, 2015 11:20 pm    Post subject:
Reply with quote

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
View user's profile Send private message
Bill Woodger

DFSORT Moderator


Joined: 09 Mar 2011
Posts: 7241

PostPosted: Fri Apr 10, 2015 1:11 am    Post subject: Reply to: Delete list of PS files within PDS member
Reply with quote

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
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 High CPU consumption Job using IAM fi... aswinir JCL & VSAM 8 Thu Dec 01, 2016 8:28 pm
No new posts JCL to delete component in a package sundaram.naveen Compuware & Other Tools 14 Tue Nov 29, 2016 6:21 pm
No new posts What is the command to check MODE of ... rohanthengal CLIST & REXX 6 Fri Nov 18, 2016 1:48 pm
No new posts Match or compare two files in VB Format anatol DFSORT/ICETOOL 14 Thu Nov 03, 2016 7:41 pm
No new posts Cobol list of programs being called biswajit.dattagupta COBOL Programming 5 Tue Nov 01, 2016 2:10 am


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