View previous topic :: View next topic
|
Author |
Message |
padmasriprasad
New User
Joined: 22 Feb 2008 Posts: 5 Location: Hyderabad
|
|
|
|
Hi ,
How can we find the DISP parameter of a Given DATASET using REXX. |
|
Back to top |
|
|
ofer71
Global Moderator
Joined: 27 Dec 2005 Posts: 2358 Location: Israel
|
|
Back to top |
|
|
padmasriprasad
New User
Joined: 22 Feb 2008 Posts: 5 Location: Hyderabad
|
|
|
|
Thanks ofer..
I have gone through the link which you have provided, could you please explain how can i use them in my REXX program...or else provide me a link where i can have the related info. |
|
Back to top |
|
|
enrico-sorichetti
Superior Member
Joined: 14 Mar 2007 Posts: 10873 Location: italy
|
|
|
|
Quote: |
How can we find the DISP parameter of a Given DATASET using REXX. |
could You please elucubrate on your requirement
... are You trying to find out how the dataset is allocated to Your job step ? |
|
Back to top |
|
|
Pedro
Global Moderator
Joined: 01 Sep 2006 Posts: 2547 Location: Silicon Valley
|
|
|
|
If you can run it in TSO, you can use the LISTA ST command. |
|
Back to top |
|
|
dick scherrer
Moderator Emeritus
Joined: 23 Nov 2006 Posts: 19244 Location: Inside the Matrix
|
|
|
|
Hello,
Quote: |
I have gone through the link which you have provided, could you please explain how can i use them in my REXX program...or else provide me a link where i can have the related info. |
That is the link to the related info. . .
You need to more clearly explain what you are looking for. What is your meaning of "a given dataset"? Any example would probably help clarify what you want to know. |
|
Back to top |
|
|
padmasriprasad
New User
Joined: 22 Feb 2008 Posts: 5 Location: Hyderabad
|
|
|
|
Given dataset means
Suppose i have a dataset called "savt.i1.temp.data"
i will read this dataset name into a variable say DSN
By using this variable(DSN) in REXX Program i want to know the DISP PARAMETER of the dataset "savt.i1.temp.data" whether it is new old shr or mod
i have a requirement to process according to the DISP parameter
Thanks for your reply |
|
Back to top |
|
|
dick scherrer
Moderator Emeritus
Joined: 23 Nov 2006 Posts: 19244 Location: Inside the Matrix
|
|
|
|
Hello,
A dataset that is on a dasd volume and is not in use has no DISP. It merely exists.
Disposition is determined by the task(s) allocating the dataset. Depending on how a dataset is to be used, it may be allocated using different DISP parameters.
You cannot use a dataset name as "input" this way.
If you explain your requirement, someone may have a suggestion. What will your code do depending on the DISP? |
|
Back to top |
|
|
padmasriprasad
New User
Joined: 22 Feb 2008 Posts: 5 Location: Hyderabad
|
|
|
|
Iam copying datasets...if a dataset with the DISP parameter as N C D then no need to copy the dataset ...simply i can change the name of the dataset...Based on the disp parameter i need to decide whether i need to copy the contents of one dataset to other or i have to replace it with new name...
EX savt.new.dataset disp=N C D i need to replace the dataset with new name say ISDN777.dataset ...to do this i need to know the disp parameter of the dataset "savt.new.dataset" through rexx
This is my requirement.. plse help |
|
Back to top |
|
|
dick scherrer
Moderator Emeritus
Joined: 23 Nov 2006 Posts: 19244 Location: Inside the Matrix
|
|
|
|
Hello,
While your question/requirement is completely clear to you it is not to others.
Please post the complete jcl from an example execution of how your process would be submitted. I realize it does not yet exist, but you can post what you intend to submit once you have code to support it.
Keep in mind that if you are copying an existing dataset, the DISP cannot be (new, cat, del) . . . |
|
Back to top |
|
|
Pedro
Global Moderator
Joined: 01 Sep 2006 Posts: 2547 Location: Silicon Valley
|
|
|
|
<wild_guess>
I think you have confused everyone by using DISP as a parameter to your rexx program. It is a common parameter in JCL.
You can use the PARSE ARG command to get the parameters passed to a rexx program. But instead of an equals sign, such as DISP=, you will probably want to use parenthesis, such as DISP(N C D)
</wild_guess> |
|
Back to top |
|
|
|