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
 
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: 31
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 Member


Joined: 30 Nov 2013
Posts: 641
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: 31
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: 182
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

Senior Member


Joined: 14 Mar 2007
Posts: 10478
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: 31
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: 7314

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 How to delete large data. Mounika Nemani DB2 1 Wed Jun 13, 2018 1:58 pm
No new posts Extracting DDL for all list of intere... Ashishpanpaliya DB2 5 Mon May 21, 2018 4:08 pm
No new posts Comparing two sequential files Mohan Kothakota COBOL Programming 14 Mon Apr 16, 2018 6:35 pm
No new posts How to list data set names with diffe... murali.andaluri CLIST & REXX 10 Thu Apr 12, 2018 11:33 pm
No new posts List of jobs ran thru scheduler ddhar All Other Mainframe Topics 1 Tue Mar 27, 2018 4:32 am

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