View previous topic :: View next topic
|
Author |
Message |
neelbiswas
New User
Joined: 19 Jan 2007 Posts: 3 Location: mumbai
|
|
|
|
Hi all,
I have and Excel sheet with names of around 3000 datasets( different high level qualifiers). I need to find out if they exist. Could any one help me with this? |
|
Back to top |
|
|
dick scherrer
Moderator Emeritus
Joined: 23 Nov 2006 Posts: 19244 Location: Inside the Matrix
|
|
|
|
Hello,
Upload the list of dataset names to the mainframe and compare the list to the output of a LISTCAT. There are multiple examples of LISTCAT in the forum. |
|
Back to top |
|
|
MBabu
Active User
Joined: 03 Aug 2008 Posts: 400 Location: Mumbai
|
|
|
|
If you upload the list and just put the data set name in col 1, then a small program like this will write what you need. Run this in batch and capture SYSTSPRT or make a minor alteration and write the output to a data set via EXECIO instead of Say.
Code: |
/* Rexx */
"ALLOC F(IN) SHR DA('X123456.DS.DATASETS') REUSE"
"EXECIO * DISKR IN (STEM NAMES. FINIS"
Do a=1 to names.0
Parse value names.a With dsname ' ' .
if "OK" == sysdsn("'"strip(dsname)"'") Then
Say dsname ' IS CATALOGED'
else
Say dsname ' IS NOT CATALOGED'
End
"FREE F(IN" |
Change as needed. |
|
Back to top |
|
|
|