Portal | Manuals | References | Downloads | Info | Programs | JCLs | Mainframe wiki | Quick Ref
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Profile Log in to check your private messages Log in
 
Partial dataset name Processing in JCL

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> JCL & VSAM
View previous topic :: :: View next topic  
Author Message
l_rajendrakumar

New User


Joined: 25 Oct 2006
Posts: 1
Location: Singapore

PostPosted: Mon Jun 23, 2014 2:52 pm    Post subject: Partial dataset name Processing in JCL
Reply with quote

I have a requirement where I have a file name which changes most of the times from my previous JCL (other application team). I need to process that (may be COPY for example into another file), can you please suggest.

Let me say, the file name is AAAA.BBBB.????.CCCC.DDDD
the value of ???? can be X001/X0002/X0003/X004...X100.
We are not sure with which value it comes, so is there any logic in JCL that we can check which ever value the file exists we can take and process it?

Note: At any point of time there will be only file, I mean ???? can have only X001/X002/X003/....X100 only one of these values.

Thanks!
Back to top
View user's profile Send private message

Akatsukami

Global Moderator


Joined: 03 Oct 2009
Posts: 1790
Location: Bloomington, IL

PostPosted: Mon Jun 23, 2014 3:48 pm    Post subject:
Reply with quote

There is no facility in JCL that does what you seem to want to do. I recommend a step running Rexx to get the DSN and write it to a tiny data set, and then read the DSN in the program and use BPXWDYN to allocate the target data set.
Back to top
View user's profile Send private message
steve-myers

Active Member


Joined: 30 Nov 2013
Posts: 672
Location: The Universe

PostPosted: Mon Jun 23, 2014 4:13 pm    Post subject: Re: Partial dataset name Processing in JCL
Reply with quote

l_rajendrakumar wrote:
Hi All,

I am having a requirement where I have a file name which changes most of the times from my previous JCL(other application team). I need to process that(may be COPY for example into another file), can you please suggest.

Let me say, the file name is AAAA.BBBB.????.CCCC.DDDD
the value of ???? can be X001/X0002/X0003/X004...X100.
We are not sure with which value it comes, so is there any logic in JCL that we can check which ever value the file exists we can take and process it?

Note: At any point of time there will be only file, I mean ???? can have only X001/X002/X003/....X100 only one of these values.

Thanks!
No. Only complete data set names can be be specified in JCL. You can use symbol substitution in data set names specified in JCL.. See the chapters "Using System Symbols and JCL symbols" and "SET Statement" in the MVS JCL Reference manual for your z/OS release.

By the way, in z/OS a “file” is the data on magnetic tape between the beginning of the tape and a “file mark”, or two “file marks.” Period. End of story. There are no “files” on disk storage. z/OS uses “data sets.” A “file” in toy and baby systems is an unstructured stream of bytes, compared to a “data set,” which has a structure.
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 -> JCL & VSAM All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts Get line number where cursor is from ... satish.ms10 CLIST & REXX 3 Wed Oct 24, 2018 12:23 am
No new posts Zipping a mainframe dataset using OSH... raviyuvi All Other Mainframe Topics 12 Thu Sep 06, 2018 7:13 pm
No new posts What is the purpose of z/OS dataset e... vasanthz All Other Mainframe Topics 3 Fri Aug 31, 2018 12:56 am
No new posts FILE versus DATASET jerryte All Other Mainframe Topics 9 Fri Jun 29, 2018 10:47 pm
No new posts Question about dataset sequence numbe... harisukumaran JCL & VSAM 23 Tue May 29, 2018 9:31 am

Facebook
Back to Top
 
Job Vacancies | Forum Rules | Bookmarks | Subscriptions | FAQ | Polls | Contact Us