View previous topic :: View next topic |
Author |
Message |
navhin Beginner
Joined: 26 Mar 2007 Posts: 20 Topics: 7 Location: india
|
Posted: Thu May 24, 2007 12:04 am Post subject: dynamically naming a flat file |
|
|
Can we include a qualifier to a DSN dynamically in a JCL while creating the file. I want to include the current date to a DSN( *.*.<date> ).
if we could do that, please show me how to do it. _________________ navhin |
|
Back to top |
|
 |
expat Intermediate

Joined: 01 Mar 2007 Posts: 475 Topics: 9 Location: Welsh Wales
|
Posted: Thu May 24, 2007 1:47 am Post subject: |
|
|
Yes, if you have a schedule package that is one of the many functions that it can do for you.
If not, it is possible but far more involved. _________________ If it's true that we are here to help others,
then what exactly are the others here for ? |
|
Back to top |
|
 |
navhin Beginner
Joined: 26 Mar 2007 Posts: 20 Topics: 7 Location: india
|
Posted: Thu May 24, 2007 2:26 am Post subject: |
|
|
expat,
can u guide me how to do it without using a schedule package _________________ navhin |
|
Back to top |
|
 |
Nic Clouston Advanced
Joined: 01 Feb 2007 Posts: 1075 Topics: 7 Location: At Home
|
Posted: Thu May 24, 2007 2:33 am Post subject: |
|
|
There have been numerous threads on this but because people keep posting utility questions in the JCL forum the search throws up many unrelated threads so you will have to wade through them. But if you have a scheduler why not use its facilities? it is simple a case of coding a symbolic name in your jcl which the scheduler resolves rather than the JCL interpreter. _________________ Utility and Program control cards are NOT, repeat NOT, JCL. |
|
Back to top |
|
 |
dbzTHEdinosauer Supermod
Joined: 20 Oct 2006 Posts: 1411 Topics: 26 Location: germany
|
Posted: Thu May 24, 2007 2:48 am Post subject: |
|
|
navhin,
I will spare you the lecture on why this is not professional and not a good idea.
this will though, limit you to one file per day. If you need to run this job more than once per day, GDG's serve this purpose. No, there is no date in the DSN, you have to look at creation date.
If in development and you want to have this, often the solution is a REXX script which will:- generate the JCL for the JOB
- build a DSN with the date as a LLQ
- submits the job
I have to ask, why do you want a date in the DSN? _________________ Dick Brenholtz
American living in Varel, Germany |
|
Back to top |
|
 |
Nic Clouston Advanced
Joined: 01 Feb 2007 Posts: 1075 Topics: 7 Location: At Home
|
Posted: Thu May 24, 2007 3:40 am Post subject: |
|
|
Right - this is the particular thread I was thinking of:
http://www.mvsforums.com/helpboards/viewtopic.php?t=8171&highlight=date+datasetname
This has a link to the relevant page in the OPC documentation - if you have some other scheduler then you will need the equivalent. There are various options so you might be able to get around the problem mentioned by Dick that a GDG would circumvent. _________________ Utility and Program control cards are NOT, repeat NOT, JCL. |
|
Back to top |
|
 |
kolusu Site Admin

Joined: 26 Nov 2002 Posts: 12376 Topics: 75 Location: San Jose
|
|
Back to top |
|
 |
expat Intermediate

Joined: 01 Mar 2007 Posts: 475 Topics: 9 Location: Welsh Wales
|
Posted: Thu May 24, 2007 7:15 am Post subject: |
|
|
I think that Kolusu and Nic have given you enough ideas, renaming a standard PS file is the easiest option. _________________ If it's true that we are here to help others,
then what exactly are the others here for ? |
|
Back to top |
|
 |
|
|