Icetool report: Display date range calculation.



JES, JES2, JCL utilities, IDCAMS, Compile & Run JCLs, PROCs etc...

Icetool report: Display date range calculation.

Postby Narine » Wed Apr 14, 2010 7:32 pm

I would like to display DATE in the report as a range. The range will be Current Day - 7 days.
Example: If the job runs today the report will display.

Page 1 THIS IS A REPORT TITLE 04/07/2010 - 04/14/2010

Is this possible with ICETOOL?
Thank you.
Narine
 
Posts: 6
Joined: Tue Apr 13, 2010 11:01 pm
Has thanked: 0 time
Been thanked: 0 time

Re: Icetool report: Display date range calculation.

Postby Frank Yaeger » Wed Apr 14, 2010 11:26 pm

You can use a DFSORT/ICETOOL job like the following to do what you asked for:

//S1 EXEC PGM=SORT
//SYSOUT DD SYSOUT=*
//SORTIN DD *
RECORD
/*
//SORTOUT DD DSN=&&S1,UNIT=SYSDA,SPACE=(TRK,(1,1)),DISP=(,PASS)
//SYSIN DD *
  OPTION COPY
  INREC IFOUTLEN=80,
    IFTHEN=(WHEN=INIT,
     BUILD=(DATE1(/)-7,DATE1(/))),
    IFTHEN=(WHEN=INIT,
     BUILD=(C'My_title,''THIS IS A REPORT TITLE ',
        6,5,C'/',1,4,C' - ',16,5,C'/',11,4,C''''))
/*
//S2 EXEC PGM=ICETOOL
//TOOLMSG DD SYSOUT=*
//DFSMSG DD SYSOUT=*
//SYMNAMES DD DSN=&&S1,DISP=(OLD,PASS)
//SYMNOUT DD SYSOUT=*
//IN DD DSN=...  input file
//OUT DD DSN=...  output file
//TOOLIN DD *
DISPLAY FROM(IN) LIST(OUT) -
   TITLE(My_title) -
  ...
/*
Frank Yaeger - DFSORT Development Team (IBM) - yaeger@us.ibm.com
Specialties: JOINKEYS, FINDREP, WHEN=GROUP, ICETOOL, Symbols, Migration
=> DFSORT/MVS is on the Web at http://www.ibm.com/storage/dfsort
User avatar
Frank Yaeger
Global moderator
 
Posts: 1079
Joined: Sat Jun 09, 2007 8:44 pm
Has thanked: 0 time
Been thanked: 15 times


Return to JCL

 


  • Related topics
    Replies
    Views
    Last post