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 

Horizontal Summing
Goto page Previous  1, 2
 
Post new topic   Reply to topic   printer-friendly view    MVSFORUMS.com Forum Index -> Utilities
View previous topic :: View next topic  
Author Message
Frank Yaeger
Sort Forum Moderator
Sort Forum Moderator


Joined: 02 Dec 2002
Posts: 1618
Topics: 31
Location: San Jose

PostPosted: Fri Jan 06, 2006 11:15 am    Post subject: Reply with quote

Quote:
i am using DFSORT REL 14.0


Quote:
That is a very OLD version of DFSORT. So most of the solutions posted here will not work.


Not true at all! With the appropriate PTFs applied (through the Dec, 2004 PTF), DFSORT R14 has all of the functions available with z/OS DFSORT V1R5 except for NULLOUT and NULLOFL.

Note that ADD has been available for DFSORT R14 since Feb, 2003.
_________________
Frank Yaeger - DFSORT Development Team (IBM)
Specialties: JOINKEYS, FINDREP, WHEN=GROUP, ICETOOL, Symbols, Migration
DFSORT is on the Web at:
www.ibm.com/storage/dfsort
Back to top
View user's profile Send private message Send e-mail Visit poster's website
Frank Yaeger
Sort Forum Moderator
Sort Forum Moderator


Joined: 02 Dec 2002
Posts: 1618
Topics: 31
Location: San Jose

PostPosted: Fri Jan 06, 2006 11:23 am    Post subject: Reply with quote

Quote:
i am using SORT to display DATE ,TIME and HEADERS and PAGE numbers also and some other processing.I am not well conversant with ICETOOL.How can i achieve the DATE,TIME,PAGE,HEADERS repeating and TRAILER.


Look at my example again. You can see that I used TRAILER1 in CTL2CNTL. This is the same TRAILER1 you can use with PGM=SORT. You can use HEADERx and TRAILERx with date, time, page and all the other functions this way with ICETOOL in the same way you would use them for PGM=SORT.

To add to the DFSORT references that Kolusu posted, I'd suggest reading through "z/OS DFSORT: Getting Started". It's an excellent tutorial, with lots of examples, that will show you how to use DFSORT, DFSORT's ICETOOL and DFSORT Symbols. You can access it online, along with all of the other DFSORT books, from:

www.ibm.com/servers/storage/support/software/sort/mvs/srtmpub.html
_________________
Frank Yaeger - DFSORT Development Team (IBM)
Specialties: JOINKEYS, FINDREP, WHEN=GROUP, ICETOOL, Symbols, Migration
DFSORT is on the Web at:
www.ibm.com/storage/dfsort
Back to top
View user's profile Send private message Send e-mail Visit poster's website
mfuser
Banned


Joined: 01 Mar 2005
Posts: 105
Topics: 58

PostPosted: Sun Jan 08, 2006 12:55 pm    Post subject: Reply with quote

I am trying to acheive the results using ICETOOL and i expecting my output to be:

Code:

***************************** Top of Data ******************************
----+----1----+----2----+----3----+----4----+----5----+----6----+----7--
                                                     PAGE:             1
                                                     DATE:    01/08/2006
                                                     TIME:      12:36:17
                                                                       
                        SUMMARY REPORT                                 
                                                                       
EMPLOYEE  EEMPLOYEE  EMPLOYEE                                           
NUMBER    NAME       DEPT                                               
-------   ---------  --------                                           
**************************** Bottom of Data ****************************


I am trying to get the results by coding the JCL

Code:

//STEP0100 EXEC PGM=ICETOOL
//TOOLMSG  DD   SYSOUT=*
//DFSMSG   DD   SYSOUT=*
//TOOLIN   DD   *
  DISPLAY FROM(IN) LIST(OUT)                                 -
  TITLE('SUMMARY REPORT')                                    -         
  HEADER('EMPLOYEE','NUMBER') ON(2,2,CH)                     -         
  HEADER('EMPLOYEE','NAME')   ON(5,4,CH)                     -         
  HEADER('EMPLOYEE','DEPT')   ON(10,3,CH)                    -     
  PAGE DATE(MD4/) TIME   


OUTPUT

Code:

----+----1----+----2----+----3----+----4----+----5----+----6----+----7----+----8
********************************* Top of Data **********************************
SUMMARY REPORT        - 1 -        01/08/2006        12:36:17                   
                                                                               
EMPLOYEE               EMPLOYEE               EMPLOYEE                         
NUMBER                 NAME                   DEPT                               
--------------------   --------------------   --------------------         



I am unable to generate the desired results and i have few queries based on my understandings which after my succesive reading i am unable to get the desired results:
a)how can we print a normal line (a simple line) not a TITLE / HEADER like below and a blank line after it

Code:

   SUMMARY REPORT



b)I am getting the results where in page no is shown as - 1 - .How do i achive my results which i am desiring as above
c)How do i truncate the heading lines to fit in the appropriate width like

Code:

EMPLOYEE
NUMBER
--------------------


to

Code:

EMPLOYEE
NUMBER
--------


d)If we need to have a display like below,how can i achieve

Code:

MARKS
     
-----

Back to top
View user's profile Send private message
mfuser
Banned


Joined: 01 Mar 2005
Posts: 105
Topics: 58

PostPosted: Mon Jan 09, 2006 6:16 am    Post subject: Reply with quote

Hai Frank and Kolusu,

I am trying my level best to understand the logic used for getting the desired results for the ICETOOL JOB,but i am unable to understand the sequence of steps.Can you please higlight the steps used so that i can get a clear understanding of the output how it was derived.I would like to take this is as an example for my excercise and i would like to learn and i would like to create similar kind of reports .Please explain me just the sequence of steps used.

Code:

//S1    EXEC  PGM=ICETOOL
//TOOLMSG   DD  SYSOUT=*
//DFSMSG    DD  SYSOUT=*
//IN DD *
 ABC A1 JAN    5
 ABC A1 JAN    9
 ABC A2 JAN    8
 ABC A2 JAN    3
 ABC A3 JAN    7
 ABC A3 FEB   12
 ABC A3 MAR    9
 ABC A4 JAN   15
 ABC A4 FEB   28
 ABC A4 MAR   31
//T1 DD DSN=&&T1,UNIT=SYSDA,SPACE=(CYL,(5,5)),DISP=(,PASS)
//T2 DD DSN=&&T2,UNIT=SYSDA,SPACE=(CYL,(5,5)),DISP=(,PASS)
//OUT DD SYSOUT=*
//TOOLIN DD *
SORT FROM(IN) TO(T1) USING(CTL1)
SPLICE FROM(T1) TO(T2) ON(2,3,CH) ON(6,2,CH) -
  WITHEACH WITH(14,4) WITH(19,4)
COPY FROM(T2) USING(CTL2)
/*
//CTL1CNTL DD *
  SORT FIELDS=(2,3,CH,A,6,2,CH,A),EQUALS
  OUTREC IFTHEN=(WHEN=INIT,
    BUILD=(1,8,9:4X,14:4X,19:4X,24:4X,
      31:13,4,36:SEQNUM,4,ZD,RESTART=(1,8),41:SEQNUM,4,ZD)),
   IFTHEN=(WHEN=(36,4,ZD,EQ,+1),OVERLAY=(9:31,4)),
   IFTHEN=(WHEN=(36,4,ZD,EQ,+2),OVERLAY=(14:31,4)),
   IFTHEN=(WHEN=(36,4,ZD,EQ,+3),OVERLAY=(19:31,4))
/*
//CTL2CNTL DD *
  OUTREC IFOUTLEN=27,
    IFTHEN=(WHEN=INIT,
      OVERLAY=(24:9,4,ZD,ADD,14,4,ZD,ADD,19,4,ZD,EDIT=(IIIT)),
       HIT=NEXT),
    IFTHEN=(WHEN=(41,4,ZD,GT,+1),OVERLAY=(2:3X))
  OUTFIL FNAMES=OUT,REMOVECC,
   TRAILER1=(9:4C'=',14:4C'=',19:4C'=',24:4C'=',/,
     9:TOT=(9,4,ZD,EDIT=(IIIT)),
    14:TOT=(14,4,ZD,EDIT=(IIIT)),
    19:TOT=(19,4,ZD,EDIT=(IIIT)),
    24:TOT=(24,4,ZD,EDIT=(IIIT)))
/*


OUTPUT
------

Code:

 ABC A1    5    9        14
     A2    8    3        11
     A3    7   12    9   28
     A4   15   28   31   74
        ==== ==== ==== ====
          35   52   40  127


Can this logic be used if i had input like below with changes ? How can i achieve the results as below if the fourth paramater can also have some values ?

Code:

----+----1----+-
 ABC A1 1      5
 ABC A1 2      9
 ABC A1 3      4
 ABC A1 4      4
 ABC A2 1      8
 ABC A2 3      3
 ABC A2 4      8
 ABC A3 1      7
 ABC A3 2     12
 ABC A3 3      9
 ABC A4 1     15
 ABC A5 2     28
 ABC A6 4     10
 ABC A7 1      1
 ABC A8 2      9
 ABC A8 4      1



OUTPUT
------

Code:

----+----1----+----2----+----3--
           1    2    3    4  SUM
        ---- ---- ---- ---- ----
 ABC A1    5    9    4    4   22
     A2    8         3    8   19
     A3    7   12    9        28
     A4   15                  15
     A5        28             28
     A6                  10   10
     A7    1                   1
     A8         9         1   10
        ==== ==== ==== ==== ====
          36   58   16   23  133

Back to top
View user's profile Send private message
Frank Yaeger
Sort Forum Moderator
Sort Forum Moderator


Joined: 02 Dec 2002
Posts: 1618
Topics: 31
Location: San Jose

PostPosted: Mon Jan 09, 2006 11:04 am    Post subject: Reply with quote

You can't do that kind of specific report layout with ICETOOL's DISPLAY. You have to use the report features of DFSORT's OUTFIL. TRAILERx is an operand of OUTFIL.

Your questions are very broad. I think the first step is for you to spend some time understanding how various things in DFSORT/ICETOOL work.

For a good overall understanding of DFSORT and ICETOOL, I'd suggest going through "z/OS DFSORT: Getting Started". It's an excellent tutorial, with lots of examples, that will show you how to use DFSORT, DFSORT's ICETOOL and DFSORT Symbols. You can access it online, along with all of the other DFSORT books, from:

www.ibm.com/servers/storage/support/software/sort/mvs/srtmpub.html

For complete details on IFTHEN and OVERLAY, see:

http://www.ibm.com/servers/storage/support/software/sort/mvs/pdug/index.html

For details on SPLICE, see:

http://publibz.boulder.ibm.com/cgi-bin/bookmgr_OS390/BOOKS/ICE1CA10/6.13?DT=20050222160456

For details on OUTFIL, see:

http://publibz.boulder.ibm.com/cgi-bin/bookmgr_OS390/BOOKS/ICE1CA10/3.13?DT=20050222160456

Note that you can access all of the DFSORT/ICETOOL books and papers from:

www.ibm.com/servers/storage/support/software/sort/mvs/srtmpub.html
_________________
Frank Yaeger - DFSORT Development Team (IBM)
Specialties: JOINKEYS, FINDREP, WHEN=GROUP, ICETOOL, Symbols, Migration
DFSORT is on the Web at:
www.ibm.com/storage/dfsort
Back to top
View user's profile Send private message Send e-mail Visit poster's website
Display posts from previous:   
Post new topic   Reply to topic   printer-friendly view    MVSFORUMS.com Forum Index -> Utilities All times are GMT - 5 Hours
Goto page Previous  1, 2
Page 2 of 2

 
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