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
 

 

Can existance of multiple(2) DSNs be checked together?

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> CLIST & REXX
View previous topic :: :: View next topic  
Author Message
prafull

New User


Joined: 08 Dec 2006
Posts: 48

PostPosted: Wed Apr 25, 2007 11:42 am    Post subject: Can existance of multiple(2) DSNs be checked together?
Reply with quote

Can existance of multiple(2) DSNs be checked using following code ?

ARG DSN
STATUS=SYSDSN("'"DSN"'")
IF STATUS='DATASET NOT FOUND' THEN SAY 'DATASET NOT FOUND'
IF STATUS='DATASET NOT FOUND' THEN EXIT 02
ELSE EXIT 0
Back to top
View user's profile Send private message

enrico-sorichetti

Global Moderator


Joined: 14 Mar 2007
Posts: 10210
Location: italy

PostPosted: Wed Apr 25, 2007 11:54 am    Post subject: Re: Can existance of multiple(2) DSNs be checked together?
Reply with quote

You tell us...

did You try ?

did You check the syntax of the SYSDSN command/function
Back to top
View user's profile Send private message
prafull

New User


Joined: 08 Dec 2006
Posts: 48

PostPosted: Wed Apr 25, 2007 12:29 pm    Post subject:
Reply with quote

enrico-sorichetti,
I am quite busy @ my workplace.This work was a bit urgent.
Yes, I will try and let you know.
Back to top
View user's profile Send private message
enrico-sorichetti

Global Moderator


Joined: 14 Mar 2007
Posts: 10210
Location: italy

PostPosted: Wed Apr 25, 2007 12:43 pm    Post subject: Re: Can existance of multiple(2) DSNs be checked together?
Reply with quote

Hi!

I know perfectly that only one dataset name is allowed,

My reply simply suggested that for this kind of questions it is usually faster to look at the docs.

and run the snippet You typed in addition to posting it here

regards

e.s


http://publibz.boulder.ibm.com/cgi-bin/bookmgr_OS390/BOOKS/ikj4a370/4.4.10?ACTION=MATCHES&REQUEST=sysdsn&TYPE=FUZZY&SHELF=IKJ4BK70.bks&DT=20060626210253&CASE=&searchTopic=TOPIC&searchText=TEXT&searchIndex=INDEX&rank=RANK&ScrollTOP=FIRSTHIT#FIRSTHIT
Back to top
View user's profile Send private message
prafull

New User


Joined: 08 Dec 2006
Posts: 48

PostPosted: Wed Apr 25, 2007 1:42 pm    Post subject:
Reply with quote

enrico-sorichetti,I had a look at this syntax but since I am not much conversant with REXX thaught there could be another way , that I could get from expets overhere..neway thanks for all.
Back to top
View user's profile Send private message
enrico-sorichetti

Global Moderator


Joined: 14 Mar 2007
Posts: 10210
Location: italy

PostPosted: Wed Apr 25, 2007 2:18 pm    Post subject: Re: Can existance of multiple(2) DSNs be checked together?
Reply with quote

It is not what You asked for,

but the ALLOCATE command takes a list of dataset;

Quote:

DATASET(dsname | *) | DSNAME(dsname | *)
specifies the name or a list of names of the data sets that are to be allocated. If a list of data set names is entered, ALLOCATE allocates and concatenates non-VSAM data sets. The data set name must include the descriptive (rightmost) qualifier and can contain a member name in parentheses.


"ALLOCATE FI(ddname) DA(dsn1 dsn2 .... dsnx ) SHR "

if You get an error then You must find out which dataset is not there
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 -> CLIST & REXX All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts Converting multiple VB files to FB fi... Viswanath Reddy JCL & VSAM 6 Mon Aug 08, 2016 11:49 pm
No new posts Execute multiple DB2 Load commands in... faizm DB2 4 Wed Aug 03, 2016 12:53 pm
This topic is locked: you cannot edit posts or make replies. JCL MULTIPLE STEP EXECUTION QUERY Susanta JCL & VSAM 18 Sat Jul 30, 2016 1:17 pm
No new posts Multiple parameters Csongor All Other Mainframe Topics 16 Thu Jun 09, 2016 7:54 pm
No new posts Define Alias for multiple Data sets u... sandy98669 JCL & VSAM 4 Fri May 27, 2016 1:07 pm


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