Portal | IBM Manuals | Downloads | Products | Refer | Info | Programs | JCLs | Forum Rules*| Site Map | Mainframe CD 
IBMMAINFRAMES.com - IBM Mainframe Support Forums Index
 
Register
 
IBMMAINFRAMES.com - IBM Mainframe Support Forums Index FAQ Search 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
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
References
PostPosted: Wed Apr 25, 2007 11:42 am    Post subject: Re: Can existance of multiple(2) DSNs be checked together? Reply with quote

enrico-sorichetti

Global Moderator


Joined: 14 Mar 2007
Posts: 2676
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: 2676
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: 2676
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
Display posts from previous:   
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> CLIST & REXX All times are GMT + 6 Hours
Page 1 of 1