Portal | Manuals | References | Downloads | Info | Programs | JCLs | Master the Mainframes
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Usergroups Profile Log in to check your private messages Log in
 

 

Date Constants in Jcl.

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> DFSORT/ICETOOL
View previous topic :: :: View next topic  
Author Message
Mane Sagar

New User


Joined: 12 Jul 2005
Posts: 41
Location: mumbai

PostPosted: Tue Mar 07, 2006 7:14 pm    Post subject: Date Constants in Jcl.
Reply with quote

Hi,

I had read a document on regarding the DATE Constants we can use in Jcl.
I have tried the test jcl that was mentioned in it but it gave an error.
Can you please correct the error in it and give a brief explanation about this.

Jcl:
Code:

//STEP01   EXEC PGM=ICETOOL,                         
//            COND=(0,NE)                           
//*                                                 
//TOOLMSG   DD  SYSOUT=*                             
//*                                                 
//DFSMSG    DD  SYSOUT=*                             
//*                                                 
//SORTIN    DD  *                                   
//*                                                 
//SORT1     DD  DSN=ACMSTMP.DATE1.TEST1,             
//            DISP=(NEW,CATLG,DELETE),               
//            UNIT=SYSDA,SPACE=(CYL,(250,100),RLSE),
//            DCB=(RECFM=FB,LRECL=231,BLKSIZE=2310) 
//*                                                 
//SORT2     DD  DSN=ACMSTMP.DATE1.TEST2,             
//            DISP=(NEW,CATLG,DELETE),               
//            UNIT=SYSDA,SPACE=(CYL,(250,100),RLSE),
//            DCB=(RECFM=FB,LRECL=231,BLKSIZE=2310) 
//*                                                 
//SORT3     DD  DSN=ACMSTMP.DATE1.TEST3,           
//            DISP=(NEW,CATLG,DELETE),             
//            UNIT=SYSDA,SPACE=(CYL,(250,100),RLSE),
//            DCB=(RECFM=FB,LRECL=231,BLKSIZE=2310)
//*                                                 
//SORT4     DD  DSN=ACMSTMP.DATE1.TEST4,           
//            DISP=(NEW,CATLG,DELETE),             
//            UNIT=SYSDA,SPACE=(CYL,(250,100),RLSE),
//            DCB=(RECFM=FB,LRECL=231,BLKSIZE=2310)
//*                                                 
//SORT5     DD  DSN=ACMSTMP.DATE1.TEST5,           
//            DISP=(NEW,CATLG,DELETE),             
//            UNIT=SYSDA,SPACE=(CYL,(250,100),RLSE),
//            DCB=(RECFM=FB,LRECL=231,BLKSIZE=2310)
//*                                                 
//SORT6     DD  DSN=ACMSTMP.DATE1.TEST6,           
//            DISP=(NEW,CATLG,DELETE),             
//            UNIT=SYSDA,SPACE=(CYL,(250,100),RLSE),
//            DCB=(RECFM=FB,LRECL=231,BLKSIZE=2310)
//*                                               
//TOOLIN    DD *  *** CONSTANT CONTROL CARDS ***   
  COPY FROM (SORTIN) USING (CTL1)                   
//CTL1CNTL  DD *  *** CONSTANT CONTROL CARDS ***   
  OUTFIL FNAMES=SORT1,                               
    OUTREC=(C'COST PRD MONTH:',C',',DATE1(-),206X)     
  OUTFIL FNAMES=SORT2,                               
    OUTREC=(C'COST PRD WEEK :',C',',TIME1(:),208X)     
  OUTFIL FNAMES=SORT3,                               
    OUTREC=(C'COST PRD TIME :',TIME=(12.),206X)       
  OUTFIL FNAMES=SORT4,                               
    OUTREC=(C'COST PRD DATE :',TIME1(:),209X)         
  OUTFIL FNAMES=SORT5,                               
    OUTREC=(C'COST PRD TIME2:',DATE=(DM4.),207X)       
  OUTFIL FNAMES=SORT6,                               
    OUTREC=(C'COST PRD DATE2:',DATE1,TIME1,203X)       
/*    END OF INPUT                                 
//*                                               
//SYSOUT       DD  SYSOUT=*
//                         


Error:

Code:

ICE600I 0 DFSORT ICETOOL UTILITY RUN STARTED                 
                                                             
ICE632I 0 SOURCE FOR ICETOOL STATEMENTS:  TOOLIN             
                                                             
                                                             
ICE630I 0 MODE IN EFFECT:  STOP                               
                                                             
          COPY FROM (SORTIN) USING (CTL1)                     
                   $                                         
ICE604A 0 ERROR IN KEYWORD, PARAMETER, OR DELIMITER           
ICE602I 0 OPERATION RETURN CODE:  12                         
                                                         
                                                             
ICE601I 0 DFSORT ICETOOL UTILITY RUN ENDED - RETURN CODE:  12
Back to top
View user's profile Send private message

superk

Moderator Team Head


Joined: 26 Apr 2004
Posts: 4649
Location: Raleigh, NC, USA

PostPosted: Tue Mar 07, 2006 7:23 pm    Post subject: Re: Date Constants in Jcl.
Reply with quote

Mane Sagar, when you post code, please enclose your code in CODE tags so that indents and formats are properly preserved. I edited your post and did that for you. I cannot tell if you added the proper indentation for the input parameters, so I also added them. Please go back and make sure that they are properly indented.
Back to top
View user's profile Send private message
Frank Yaeger

DFSORT Moderator


Joined: 15 Feb 2005
Posts: 7130
Location: San Jose, CA

PostPosted: Tue Mar 07, 2006 9:33 pm    Post subject:
Reply with quote

The $ under the COPY operator shows you where the problem is. You have a blank between FROM and (SORTIN) that shouldn't be there. The COPY operator should look like this:

Code:

  COPY FROM(SORTIN) USING(CTL1)


Also, the LRECL values you're specifying for the SORTx DDs do NOT match the OUTREC record lengths. Remove the DCB info and let DFSORT set it automatically, e.g.

Code:

//SORT1     DD  DSN=ACMSTMP.DATE1.TEST1,             
//            DISP=(NEW,CATLG,DELETE),               
//            UNIT=SYSDA,SPACE=(CYL,(250,100),RLSE)
Back to top
View user's profile Send private message
Mane Sagar

New User


Joined: 12 Jul 2005
Posts: 41
Location: mumbai

PostPosted: Wed Mar 08, 2006 6:13 pm    Post subject: Re: Date Constants in Jcl.
Reply with quote

Hi Frank and Superk,

Thanks a lot for the corrections.
I will make this changes and try a test run again.

Thanks again.
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 -> DFSORT/ICETOOL All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts How to add header with Date(YYMMDD) i... Rajan Moorthy DFSORT/ICETOOL 2 Thu Jul 06, 2017 11:44 pm
No new posts Validate date and numeric fields and ... Rick Silvers DFSORT/ICETOOL 6 Thu May 11, 2017 6:51 pm
No new posts LISTIDR compiled date/time jerryte IBM Tools 3 Thu Apr 20, 2017 7:37 pm
No new posts SUBSTR for Date functions Shaheen Shaik DB2 4 Thu Apr 06, 2017 2:14 pm
No new posts Date and time format in CICS Chandru3183 CICS 2 Sat Mar 18, 2017 12:46 pm


Facebook
Back to Top
 
Mainframe Wiki | Forum Rules | Bookmarks | Subscriptions | FAQ | Tutorials | Contact Us