MVSFORUMS.com Forum Index MVSFORUMS.com
A Community of and for MVS Professionals
 
 FAQFAQ   SearchSearch   Quick Manuals   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Creating Dataset containing a hard-coded Date

 
Post new topic   Reply to topic   printer-friendly view    MVSFORUMS.com Forum Index -> Job Control Language(JCL)
View previous topic :: View next topic  
Author Message
vini
Intermediate


Joined: 12 Jan 2004
Posts: 240
Topics: 48
Location: Maryland

PostPosted: Tue Jul 14, 2009 1:11 pm    Post subject: Creating Dataset containing a hard-coded Date Reply with quote

Hi Gurus,

Any utility will work for me as long as this Dataset is in a Cobol program readable format.
Dataset to contain just one record of LRECL 80 and contain 06/30/2009'.

This has to be done through a JCL and Utility, not manually.

I did try to search but did not get back any results. Not saying this has not been discussed before but I could not locate using the parameters I used for searching.

Thanks!
Vini
Back to top
View user's profile Send private message
kolusu
Site Admin
Site Admin


Joined: 26 Nov 2002
Posts: 12378
Topics: 75
Location: San Jose

PostPosted: Tue Jul 14, 2009 1:36 pm    Post subject: Reply with quote

vini wrote:
Any utility will work for me as long as this Dataset is in a Cobol program readable format. Dataset to contain just one record of LRECL 80 and contain 06/30/2009'.


Is that value going to change or is it always the same constant?

Kolusu
_________________
Kolusu
www.linkedin.com/in/kolusu
Back to top
View user's profile Send private message Send e-mail Visit poster's website
vini
Intermediate


Joined: 12 Jan 2004
Posts: 240
Topics: 48
Location: Maryland

PostPosted: Tue Jul 14, 2009 1:39 pm    Post subject: Reply with quote

Hi Kolusu,

Date is to be constant as this JCL is going to be run for the first instance only like a one time only job. Subsequently the pgm is going to update the date each run.

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


Joined: 26 Nov 2002
Posts: 12378
Topics: 75
Location: San Jose

PostPosted: Tue Jul 14, 2009 1:54 pm    Post subject: Reply with quote

vini,

The following DFSORT JCL will give you the desired results

Code:

//STEP0100 EXEC PGM=SORT                                 
//SYSOUT   DD SYSOUT=*                                   
//SORTIN   DD DUMMY,DCB=(LRECL=80,RECFM=FB,BLKSIZE=27920)
//SORTOUT  DD SYSOUT=*                                   
//SYSIN    DD *                                         
  SORT FIELDS=COPY                                       
  OUTFIL REMOVECC,HEADER1=('06/30/2009',80:X)           
/*

_________________
Kolusu
www.linkedin.com/in/kolusu
Back to top
View user's profile Send private message Send e-mail Visit poster's website
vini
Intermediate


Joined: 12 Jan 2004
Posts: 240
Topics: 48
Location: Maryland

PostPosted: Tue Jul 14, 2009 2:41 pm    Post subject: Reply with quote

Thanks Kolusu ..your a God sent for folks like me who resort to the forum each time we have some exotic stuff to be done using JCL. Very Happy
Most of the time we are copy paste gurus in regard to JCL Laughing Frank has been equally instrumental in assisting with similar requests.
Back to top
View user's profile Send private message
Anuj Dhawan
Intermediate


Joined: 19 Jul 2007
Posts: 298
Topics: 7
Location: Mumbai,India

PostPosted: Thu Sep 17, 2009 1:48 am    Post subject: Reply with quote

mmm... why could not you use ISPF 3.2 to have a file as you desire, I wonder.
_________________
Regards,
Anuj
Back to top
View user's profile Send private message
kolusu
Site Admin
Site Admin


Joined: 26 Nov 2002
Posts: 12378
Topics: 75
Location: San Jose

PostPosted: Thu Sep 17, 2009 2:53 pm    Post subject: Reply with quote

Anuj Dhawan wrote:
mmm... why could not you use ISPF 3.2 to have a file as you desire, I wonder.


well can you create a dataset on production site with HLQ other than your user id?
_________________
Kolusu
www.linkedin.com/in/kolusu
Back to top
View user's profile Send private message Send e-mail Visit poster's website
Anuj Dhawan
Intermediate


Joined: 19 Jul 2007
Posts: 298
Topics: 7
Location: Mumbai,India

PostPosted: Thu Sep 17, 2009 11:40 pm    Post subject: Reply with quote

Hi Kolusu,

Before I answer your question, I must have read this from very first post
Quote:
This has to be done through a JCL and Utility, not manually.
I saw the problem as one time adhoc task. Embarassed
_________________
Regards,
Anuj
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic   printer-friendly view    MVSFORUMS.com Forum Index -> Job Control Language(JCL) All times are GMT - 5 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


MVSFORUMS
Powered by phpBB © 2001, 2005 phpBB Group