View previous topic :: View next topic
|
Author |
Message |
Seppe
New User
Joined: 01 Apr 2009 Posts: 33 Location: Rome - Italy
|
|
|
|
hi all.
i have a clist that modify the members of a lib...
it's all ok but i have only a little problem:
first, my clist asks the name of lib... if it exists it's ok, but if it not exists the clist goes abend...
In this case i don't want end the clist but i want open another lib...
There is a command to verify if a lib exist first to open it?
EXCUSE ME FOR MY ENGLISH... |
|
Back to top |
|
|
expat
Global Moderator
Joined: 14 Mar 2007 Posts: 8797 Location: Welsh Wales
|
|
|
|
Take a look at SYSDSN |
|
Back to top |
|
|
vasanthz
Global Moderator
Joined: 28 Aug 2007 Posts: 1742 Location: Tirupur, India
|
|
|
|
Hi,
LISTDSI should be able to help you,
check the variable X. if 0 continue processing, if 16 skip to next dataset.
Code: |
/*REXX*/
VAR1="XK89.DREAM.CNTL4"
VAR4 = STRIP("'"VAR1"'")
X = LISTDSI(VAR4)
SAY 'X IS 0 IF DATASET EXISTS, 16 IF ITS NOT FOUND. X IS' X
EXIT |
Hope this helps
Thanks & Regards, |
|
Back to top |
|
|
Seppe
New User
Joined: 01 Apr 2009 Posts: 33 Location: Rome - Italy
|
|
|
|
can i use this command in clist? |
|
Back to top |
|
|
vasanthz
Global Moderator
Joined: 28 Aug 2007 Posts: 1742 Location: Tirupur, India
|
|
Back to top |
|
|
|