IBM Mainframe Forum Index
 
Log In
 
IBM Mainframe Forum Index Mainframe: Search IBM Mainframe Forum: FAQ Register
 

SORT - totals of a column


IBM Mainframe Forums -> DFSORT/ICETOOL
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
ozgurseyrek

New User


Joined: 22 Feb 2008
Posts: 70
Location: Turkey

PostPosted: Fri Dec 05, 2008 5:16 pm
Reply with quote

Hello,
my inout data is like that;

Code:

DENIZ     ;60001     ;15.01.2008;G10;11   ; 000000000000080,00;
DENIZ     ;60005     ;18.01.2008;BUS;10   ; 000000000000455,00;
DENIZ     ;60006     ;01.02.2008;T10;10   ; 000000000000240,00;
DENIZ     ;60007     ;05.02.2008;T20;10   ; 000000000000069,00;
DENIZ     ;60008     ;15.01.2008;G10;11   ; 000000000000000,00;
DENIZ     ;60014     ;29.01.2008;G10;11   ; 000000000000000,00;


I want to output same data plus 1 line at the bottom (Totals of last column);

Code:

DENIZ     ;60001     ;15.01.2008;G10;11   ; 000000000000080,00;
DENIZ     ;60005     ;18.01.2008;BUS;10   ; 000000000000455,00;
DENIZ     ;60006     ;01.02.2008;T10;10   ; 000000000000240,00;
DENIZ     ;60007     ;05.02.2008;T20;10   ; 000000000000069,00;
DENIZ     ;60008     ;15.01.2008;G10;11   ; 000000000000000,00;
DENIZ     ;60014     ;29.01.2008;G10;11   ; 000000000000000,00;
                                            000000000000844,00;


is it possible?
Back to top
View user's profile Send private message
Frank Yaeger

DFSORT Developer


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

PostPosted: Fri Dec 05, 2008 10:43 pm
Reply with quote

Here's a DFSORT job that will do what you asked for:

Code:

//S1    EXEC  PGM=ICEMAN
//SYSOUT    DD  SYSOUT=*
//SORTIN DD DSN=... input file
//SORTOUT DD DSN=... output file
//SYSIN    DD    *
  OPTION COPY
  OUTFIL REMOVECC,
    TRAILER1=(45:TOT=(45,18,UFF,EDIT=(TTTTTTTTTTTTTTT,TT)),C';')
/*
Back to top
View user's profile Send private message
ozgurseyrek

New User


Joined: 22 Feb 2008
Posts: 70
Location: Turkey

PostPosted: Sat Dec 06, 2008 4:25 pm
Reply with quote

thank you very much...
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic View Bookmarks
All times are GMT + 6 Hours
Forum Index -> DFSORT/ICETOOL

 


Similar Topics
Topic Forum Replies
No new posts How to split large record length file... DFSORT/ICETOOL 8
No new posts JCL sort card - get first day and las... JCL & VSAM 9
No new posts How to load to DB2 with column level ... DB2 6
No new posts RC query -Time column CA Products 3
No new posts Sort First/last record of a subset th... DFSORT/ICETOOL 7
Search our Forums:

Back to Top