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
 

 

Search Uncat DSNs in the Storage Group

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

New User


Joined: 17 Oct 2008
Posts: 18
Location: USA

PostPosted: Mon Aug 02, 2010 7:43 am    Post subject: Search Uncat DSNs in the Storage Group
Reply with quote

Hello,

I do have a requirement to cleanup the uncataloged datasets from the Storage Group. I tried with the following JCL and it searches for the datasets which are migrated to ML2 as well. But, I want to exclude the datasets which are already migrated to ML2 from the search criteria.

JCL:-

//STEP01 EXEC PGM=ADRDSSU,REGION=0M,PARM=('TYPRUN=NORUN')
//SYSPRINT DD SYSOUT=*
//DSNOUT DD DUMMY
//SYSIN DD *
DUMP -
STORGRP(XXXXXXXX) -
OUTDD(DSNOUT) -
DS(INCL(**) -
EXCL(SYS1.**,CATALOG.**) -
BY((CATLG,EQ,NO))) -
DELETE PURGE
//

Is there a way to achieve this? icon_idea.gif
Back to top
View user's profile Send private message

expat

Global Moderator


Joined: 14 Mar 2007
Posts: 8593
Location: Back in jolly old England

PostPosted: Mon Aug 02, 2010 4:31 pm    Post subject:
Reply with quote

Can you post the output from the run which accesses ML2 datasets
Back to top
View user's profile Send private message
Pete Wilson

Active User


Joined: 31 Dec 2009
Posts: 437
Location: London

PostPosted: Wed Aug 11, 2010 2:52 pm    Post subject:
Reply with quote

You are trying to do a Logical DUMP DELETE which does not work when dealing with uncataloged datasets. Because it is logical it tries to go via the catalog hence reference to migrated data. You have to do a Physical DUMP at the volume level to achieve what you want. Unfortunately you have to specify each volume you want to process for a Phsyical DUMP as STORGRP is not an option. You can only have 255 statements in teh SYSIN too so you may have to do multiple jobsteps.
e.g.
//STEP01 EXEC PGM=ADRDSSU,REGION=512M,PARM=('TYPRUN=NORUN')
//SYSPRINT DD SYSOUT=*
//XIT DD DUMMY
//SYSIN DD *
DUMP ODD(XIT) PURGE DEL OPT(4) -
DS(INCL(**) -
EXCL(SYS1.**,CATALOG.**) -
BY((CATLG,EQ,NO),(REFDT,NE.*))) -
IDY( -
(volser1) -
(volser2) -
...etc
)
//

I'd suggest you analyze why all these uncataloged datasets have got like that in SMS managed volumes, which in theory shouldn't have any uncataloged. A bunch of IDCAMS DIAGNOSE jobs should flush out a number of issues, but you need to find out what caused these in the first place and jump on whoever is the culprit!
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 Syncsort Help to group fields sudhakarraju SYNCSORT 6 Thu Dec 29, 2016 1:38 am
No new posts abend sort based on count records in ... anatol DFSORT/ICETOOL 5 Mon Oct 17, 2016 10:10 pm
No new posts Get Record count in summary record fo... Atul Banke DFSORT/ICETOOL 21 Fri Sep 23, 2016 4:17 pm
No new posts Select first 2 group data vice_versa DFSORT/ICETOOL 10 Mon Jun 13, 2016 2:21 pm
No new posts Search a Load Module sreekanth1984 TSO/ISPF 8 Tue Jun 07, 2016 8:45 pm


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